]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
Revert "byteorder: properly detect endianness"
authorSage Weil <sage@newdream.net>
Thu, 8 Oct 2009 21:58:03 +0000 (14:58 -0700)
committerSage Weil <sage@newdream.net>
Thu, 8 Oct 2009 21:58:03 +0000 (14:58 -0700)
Or not!

This reverts commit a33441c4b274d840432ba553db463cbee1f1a480.

src/include/byteorder.h

index d65493244ae17a81b5d3c73c74ec9d313889b91a..cdd003781dd763c6f69a1cfeb7d55c1f5dd7454f 100644 (file)
@@ -31,14 +31,11 @@ static __inline__ __u64 swab64(__u64 val)
 }
 
 // mswab == maybe swab (if not LE)
-#if defined(__BIG_ENDIAN__) || defined(__BIG_ENDIAN)
+#if __BYTEORDER == __BIG_ENDIAN
 # define mswab64(a) swab64(a)
 # define mswab32(a) swab32(a)
 # define mswab16(a) swab16(a)
 #else
-# if !defined(__LITTLE_ENDIAN__) && !defined(__LITTLE_ENDIAN)
-#  warning unknown endianness, assuming little
-# endif
 # define mswab64(a) (a)
 # define mswab32(a) (a)
 # define mswab16(a) (a)