X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=include%2Fcompiler.h;h=47c296e202d1e97388d3207e4f0c2321831a2f87;hb=5c27b3b75988f13e313e028dc6849c5c531a5f75;hp=9afc11be1942d6b9e2c4ba19ed059fd288447685;hpb=f2c8d7f591e28d3437155c7a6eae8c8d9e3fe552;p=karo-tx-uboot.git diff --git a/include/compiler.h b/include/compiler.h index 9afc11be19..47c296e202 100644 --- a/include/compiler.h +++ b/include/compiler.h @@ -48,6 +48,10 @@ # include typedef unsigned long ulong; #endif +#ifdef __FreeBSD__ +# include /* htole32 and friends */ +#endif + #include typedef uint8_t __u8; @@ -108,6 +112,14 @@ typedef unsigned int uint; #else /* !USE_HOSTCC */ +#ifdef CONFIG_USE_STDINT +/* Provided by gcc. */ +#include +#else +/* Type for `void *' pointers. */ +typedef unsigned long int uintptr_t; +#endif + #include #include #include @@ -124,14 +136,8 @@ typedef unsigned int uint; #define __WORDSIZE 32 #endif -/* Type for `void *' pointers. */ -typedef unsigned long int uintptr_t; - #endif /* USE_HOSTCC */ -/* compiler options */ -#define uninitialized_var(x) x = x - #define likely(x) __builtin_expect(!!(x), 1) #define unlikely(x) __builtin_expect(!!(x), 0)