Skip to content

Commit

Permalink
[ARM] use the new byteorder headers
Browse files Browse the repository at this point in the history
Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Harvey Harrison authored and Russell King committed Aug 27, 2008
1 parent e4e4146 commit ae82cbf
Showing 1 changed file with 11 additions and 14 deletions.
25 changes: 11 additions & 14 deletions arch/arm/include/asm/byteorder.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,15 @@
#include <linux/compiler.h>
#include <asm/types.h>

static inline __attribute_const__ __u32 ___arch__swab32(__u32 x)
#ifdef __ARMEB__
# define __BIG_ENDIAN
#else
# define __LITTLE_ENDIAN
#endif

#define __SWAB_64_THRU_32__

static inline __attribute_const__ __u32 __arch_swab32(__u32 x)
{
__u32 t;

Expand All @@ -40,19 +48,8 @@ static inline __attribute_const__ __u32 ___arch__swab32(__u32 x)

return x;
}
#define __arch_swab32 __arch_swab32

#define __arch__swab32(x) ___arch__swab32(x)

#if !defined(__STRICT_ANSI__) || defined(__KERNEL__)
# define __BYTEORDER_HAS_U64__
# define __SWAB_64_THRU_32__
#endif

#ifdef __ARMEB__
#include <linux/byteorder/big_endian.h>
#else
#include <linux/byteorder/little_endian.h>
#endif
#include <linux/byteorder.h>

#endif

0 comments on commit ae82cbf

Please sign in to comment.