I think I've found a small bug in asm-ppc/byteorder.h. The problem is that symbol
__BYTEORDER_HAS_U64__ is defined only if __KERNEL__ is defined but on other archs
it's defined also if __STRICT_ANSI__ is not defined and this is IMHO right. Patch
which fixes it is below.
Honza
----------------------------------------------------------------------------------
--- linux/include/asm-ppc/byteorder.h Fri Aug 10 14:25:17 2001
+++ linux/include/asm-ppc/byteorder.h Fri Aug 10 14:28:10 2001
@@ -6,8 +6,8 @@
#include <asm/types.h>
-#ifdef __KERNEL__
#ifdef __GNUC__
+#ifdef __KERNEL__
extern __inline__ unsigned ld_le16(const volatile unsigned short *addr)
{
@@ -72,12 +72,13 @@
#define __arch__swab16s(addr) st_le16(addr,*addr)
#define __arch__swab32s(addr) st_le32(addr,*addr)
-#ifndef __STRICT_ANSI__
+#endif /* __KERNEL__ */
+
+#if !defined(__STRICT_ANSI__) || defined(__KERNEL__)
#define __BYTEORDER_HAS_U64__
#endif
#endif /* __GNUC__ */
-#endif /* __KERNEL__ */
#include <linux/byteorder/big_endian.h>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/