From: Linus Torvalds Date: Wed, 7 Jan 2009 05:17:57 +0000 (-0800) Subject: Fix up 64-bit byte swaps for most 32-bit architectures X-Git-Tag: MMI-PSA29.97-13-9~30093 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ede6f5aea054d3fb67c78857f7abdee602302043;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git Fix up 64-bit byte swaps for most 32-bit architectures The __SWAB_64_THRU_32__ case of a 64-bit byte swap was depending on the no-longer-existant ___swab32() method (three underscores). We got rid of some of the worst indirection and complexity, and now it should just use the 32-bit swab function that was defined right above it. Reported-and-tested-by: Nicolas Pitre Reported-by: Benjamin Herrenschmidt Cc: Harvey Harrison Signed-off-by: Linus Torvalds --- diff --git a/include/linux/swab.h b/include/linux/swab.h index 9a2d33e0a98a..be5284d4a053 100644 --- a/include/linux/swab.h +++ b/include/linux/swab.h @@ -68,7 +68,7 @@ static inline __attribute_const__ __u64 __fswab64(__u64 val) #elif defined(__SWAB_64_THRU_32__) __u32 h = val >> 32; __u32 l = val & ((1ULL << 32) - 1); - return (((__u64)___swab32(l)) << 32) | ((__u64)(___swab32(h))); + return (((__u64)__fswab32(l)) << 32) | ((__u64)(__fswab32(h))); #else return ___constant_swab64(val); #endif