You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

byteswap.h 511B

12345678910111213141516171819202122
  1. #ifndef ETHERBOOT_BYTESWAP_H
  2. #define ETHERBOOT_BYTESWAP_H
  3. #include "endian.h"
  4. #include "bits/byteswap.h"
  5. #if __BYTE_ORDER == __LITTLE_ENDIAN
  6. #include "little_bswap.h"
  7. #endif
  8. #if __BYTE_ORDER == __BIG_ENDIAN
  9. #include "big_bswap.h"
  10. #endif
  11. /* Make routines available to all */
  12. #define swap64(x) __bswap_64(x)
  13. #define swap32(x) __bswap_32(x)
  14. #define swap16(x) __bswap_16(x)
  15. #define bswap_64(x) __bswap_64(x)
  16. #define bswap_32(x) __bswap_32(x)
  17. #define bswap_16(x) __bswap_16(x)
  18. #endif /* ETHERBOOT_BYTESWAP_H */