ureg.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. #ifndef __UREG_H
  2. #define __UREG_H
  3. #if !defined(_PLAN9_SOURCE)
  4. This header file is an extension to ANSI/POSIX
  5. #endif
  6. struct Ureg
  7. {
  8. union {
  9. unsigned long pc;
  10. unsigned long regs[1];
  11. };
  12. unsigned long r1; /* link */
  13. union{
  14. unsigned long r2;
  15. unsigned long sp;
  16. unsigned long usp;
  17. };
  18. unsigned long r3; /* sb */
  19. unsigned long r4;
  20. unsigned long r5;
  21. unsigned long r6; /* up in kernel */
  22. unsigned long r7; /* m in kernel */
  23. union{
  24. unsigned long r8;
  25. unsigned long arg;
  26. unsigned long ret;
  27. };
  28. unsigned long r9;
  29. unsigned long r10;
  30. unsigned long r11;
  31. unsigned long r12;
  32. unsigned long r13;
  33. unsigned long r14;
  34. unsigned long r15;
  35. unsigned long r16;
  36. unsigned long r17;
  37. unsigned long r18;
  38. unsigned long r19;
  39. unsigned long r20;
  40. unsigned long r21;
  41. unsigned long r22;
  42. unsigned long r23;
  43. unsigned long r24;
  44. unsigned long r25;
  45. unsigned long r26;
  46. unsigned long r27;
  47. unsigned long r28;
  48. unsigned long r29;
  49. unsigned long r30;
  50. unsigned long r31;
  51. /* csrs: generally supervisor ones */
  52. unsigned long status;
  53. unsigned long ie;
  54. union {
  55. unsigned long cause;
  56. unsigned long type;
  57. };
  58. unsigned long tval; /* faulting address */
  59. };
  60. #endif