From 174256aba7a8de23b05747539800664d2c7b45c7 Mon Sep 17 00:00:00 2001 From: Adrian Bunk Date: Sat, 10 Feb 2007 01:46:06 -0800 Subject: [PATCH] --- yaml --- r: 47591 b: refs/heads/master c: bfb58478fe2f8cbbb776d910ff3549515e3c8f4f h: refs/heads/master i: 47589: ff58099fbbcd4b7e80e9bfe83fd91f0c7fa28872 47587: d62812fe8edfb990c534efa72ba47d2122cb81c4 47583: 09e5e632b9b27571f1de86663c623d99cdee9d2b v: v3 --- [refs] | 2 +- trunk/include/linux/byteorder/Kbuild | 1 - trunk/include/linux/byteorder/swabb.h | 13 ++++--------- 3 files changed, 5 insertions(+), 11 deletions(-) diff --git a/[refs] b/[refs] index e6a9fc3a088e..c036850f508e 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a9cccd34372f7075e8746395609bc78f0fbaf204 +refs/heads/master: bfb58478fe2f8cbbb776d910ff3549515e3c8f4f diff --git a/trunk/include/linux/byteorder/Kbuild b/trunk/include/linux/byteorder/Kbuild index d39dc0f7c67e..79bedddfd9ca 100644 --- a/trunk/include/linux/byteorder/Kbuild +++ b/trunk/include/linux/byteorder/Kbuild @@ -2,5 +2,4 @@ header-y += big_endian.h header-y += little_endian.h unifdef-y += generic.h -unifdef-y += swabb.h unifdef-y += swab.h diff --git a/trunk/include/linux/byteorder/swabb.h b/trunk/include/linux/byteorder/swabb.h index ae5e5f914bf4..8c780c7d779e 100644 --- a/trunk/include/linux/byteorder/swabb.h +++ b/trunk/include/linux/byteorder/swabb.h @@ -25,6 +25,8 @@ * */ +#include + #define ___swahw32(x) \ ({ \ __u32 __x = (x); \ @@ -77,19 +79,14 @@ /* * Allow constant folding */ -#if defined(__GNUC__) && defined(__OPTIMIZE__) -# define __swahw32(x) \ +#define __swahw32(x) \ (__builtin_constant_p((__u32)(x)) ? \ ___swahw32((x)) : \ __fswahw32((x))) -# define __swahb32(x) \ +#define __swahb32(x) \ (__builtin_constant_p((__u32)(x)) ? \ ___swahb32((x)) : \ __fswahb32((x))) -#else -# define __swahw32(x) __fswahw32(x) -# define __swahb32(x) __fswahb32(x) -#endif /* OPTIMIZE */ static inline __u32 __fswahw32(__u32 x) @@ -128,13 +125,11 @@ static inline void __swahb32s(__u32 *addr) */ #endif /* __BYTEORDER_HAS_U64__ */ -#if defined(__KERNEL__) #define swahw32 __swahw32 #define swahb32 __swahb32 #define swahw32p __swahw32p #define swahb32p __swahb32p #define swahw32s __swahw32s #define swahb32s __swahb32s -#endif #endif /* _LINUX_BYTEORDER_SWABB_H */