endian.h 484 B

12345678910111213141516
  1. /* The MIPS architecture has selectable endianness.
  2. Linux/MIPS exists in two both little and big endian flavours and we
  3. want to be able to share the installed headerfiles between both,
  4. so we define __BYTE_ORDER based on GCC's predefines. */
  5. #ifndef _ENDIAN_H
  6. # error "Never use <bits/endian.h> directly; include <endian.h> instead."
  7. #endif
  8. #ifdef __MIPSEB__
  9. # define __BYTE_ORDER __BIG_ENDIAN
  10. #else
  11. # ifdef __MIPSEL__
  12. # define __BYTE_ORDER __LITTLE_ENDIAN
  13. # endif
  14. #endif