aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_arch.h
diff options
context:
space:
mode:
authorNathan Scott <nathans@sgi.com>2005-09-08 01:30:05 -0400
committerNathan Scott <nathans@sgi.com>2005-09-08 01:30:05 -0400
commitf016bad6be720496b5582a59738bca00a26f876c (patch)
tree2a99f1eec64972538fc10b13e8076ff4b7c17e0c /fs/xfs/xfs_arch.h
parentcaf39e87cc1182f7dae84eefc43ca14d54c78ef9 (diff)
[XFS] Cleanup some -Wundef flag warnings in the endian macros (thanks
Christoph). SGI-PV: 942400 SGI-Modid: xfs-linux-melb:xfs-kern:23771a Signed-off-by: Nathan Scott <nathans@sgi.com>
Diffstat (limited to 'fs/xfs/xfs_arch.h')
-rw-r--r--fs/xfs/xfs_arch.h22
1 files changed, 14 insertions, 8 deletions
diff --git a/fs/xfs/xfs_arch.h b/fs/xfs/xfs_arch.h
index ae35189b3d70..5ab0dd885b1b 100644
--- a/fs/xfs/xfs_arch.h
+++ b/fs/xfs/xfs_arch.h
@@ -40,22 +40,28 @@
40 40
41#include <asm/byteorder.h> 41#include <asm/byteorder.h>
42 42
43#ifdef __LITTLE_ENDIAN
44# define __BYTE_ORDER __LITTLE_ENDIAN
45#endif
46#ifdef __BIG_ENDIAN 43#ifdef __BIG_ENDIAN
47# define __BYTE_ORDER __BIG_ENDIAN 44#define XFS_NATIVE_HOST 1
45#else
46#undef XFS_NATIVE_HOST
47#endif
48
49#else /* __KERNEL__ */
50
51#if __BYTE_ORDER == __BIG_ENDIAN
52#define XFS_NATIVE_HOST 1
53#else
54#undef XFS_NATIVE_HOST
48#endif 55#endif
49 56
50#endif /* __KERNEL__ */ 57#endif /* __KERNEL__ */
51 58
52/* do we need conversion? */ 59/* do we need conversion? */
53
54#define ARCH_NOCONVERT 1 60#define ARCH_NOCONVERT 1
55#if __BYTE_ORDER == __LITTLE_ENDIAN 61#ifdef XFS_NATIVE_HOST
56# define ARCH_CONVERT 0
57#else
58# define ARCH_CONVERT ARCH_NOCONVERT 62# define ARCH_CONVERT ARCH_NOCONVERT
63#else
64# define ARCH_CONVERT 0
59#endif 65#endif
60 66
61/* generic swapping macros */ 67/* generic swapping macros */