blob: cc8e418cfd14a10c65fc1dc8a3f41c78178db713 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001#ifndef _CRIS_BYTEORDER_H
2#define _CRIS_BYTEORDER_H
3
4#ifdef __GNUC__
5
David Woodhouseed9526b2006-09-21 09:33:55 +01006#ifdef __KERNEL__
Jesper Nilsson556dcee2008-10-21 17:45:58 +02007#include <arch/byteorder.h>
Linus Torvalds1da177e2005-04-16 15:20:36 -07008
9/* defines are necessary because the other files detect the presence
10 * of a defined __arch_swab32, not an inline
11 */
Linus Torvalds1da177e2005-04-16 15:20:36 -070012#define __arch__swab32(x) ___arch__swab32(x)
13#define __arch__swab16(x) ___arch__swab16(x)
David Woodhouseed9526b2006-09-21 09:33:55 +010014#endif /* __KERNEL__ */
Linus Torvalds1da177e2005-04-16 15:20:36 -070015
16#if !defined(__STRICT_ANSI__) || defined(__KERNEL__)
17# define __BYTEORDER_HAS_U64__
18# define __SWAB_64_THRU_32__
19#endif
20
21#endif /* __GNUC__ */
22
23#include <linux/byteorder/little_endian.h>
24
25#endif
26
27