libgcc.h 682 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef __ASM_LIBGCC_H
  3. #define __ASM_LIBGCC_H
  4. #include <asm/byteorder.h>
  5. typedef int word_type __attribute__ ((mode (__word__)));
  6. #ifdef __BIG_ENDIAN
  7. struct DWstruct {
  8. int high, low;
  9. };
  10. struct TWstruct {
  11. long long high, low;
  12. };
  13. #elif defined(__LITTLE_ENDIAN)
  14. struct DWstruct {
  15. int low, high;
  16. };
  17. struct TWstruct {
  18. long long low, high;
  19. };
  20. #else
  21. #error I feel sick.
  22. #endif
  23. typedef union {
  24. struct DWstruct s;
  25. long long ll;
  26. } DWunion;
  27. #if defined(CONFIG_64BIT) && defined(CONFIG_CPU_MIPSR6)
  28. typedef int ti_type __attribute__((mode(TI)));
  29. typedef union {
  30. struct TWstruct s;
  31. ti_type ti;
  32. } TWunion;
  33. #endif
  34. #endif /* __ASM_LIBGCC_H */