diff options
Diffstat (limited to 'src/include/little_bswap.h')
| -rw-r--r-- | src/include/little_bswap.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/include/little_bswap.h b/src/include/little_bswap.h new file mode 100644 index 000000000..35918530b --- /dev/null +++ b/src/include/little_bswap.h @@ -0,0 +1,17 @@ +#ifndef ETHERBOOT_LITTLE_BSWAP_H +#define ETHERBOOT_LITTLE_BSWAP_H + +#define ntohl(x) __bswap_32(x) +#define htonl(x) __bswap_32(x) +#define ntohs(x) __bswap_16(x) +#define htons(x) __bswap_16(x) +#define cpu_to_le32(x) (x) +#define cpu_to_le16(x) (x) +#define cpu_to_be32(x) __bswap_32(x) +#define cpu_to_be16(x) __bswap_16(x) +#define le32_to_cpu(x) (x) +#define le16_to_cpu(x) (x) +#define be32_to_cpu(x) __bswap_32(x) +#define be16_to_cpu(x) __bswap_16(x) + +#endif /* ETHERBOOT_LITTLE_BSWAP_H */ |
