ptrace.h 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. /* SPDX-License-Identifier: GPL-2.0 WITH Linux-syscall-note */
  2. #ifndef _UAPI_M68K_PTRACE_H
  3. #define _UAPI_M68K_PTRACE_H
  4. #define PT_D1 0
  5. #define PT_D2 1
  6. #define PT_D3 2
  7. #define PT_D4 3
  8. #define PT_D5 4
  9. #define PT_D6 5
  10. #define PT_D7 6
  11. #define PT_A0 7
  12. #define PT_A1 8
  13. #define PT_A2 9
  14. #define PT_A3 10
  15. #define PT_A4 11
  16. #define PT_A5 12
  17. #define PT_A6 13
  18. #define PT_D0 14
  19. #define PT_USP 15
  20. #define PT_ORIG_D0 16
  21. #define PT_SR 17
  22. #define PT_PC 18
  23. #ifndef __ASSEMBLY__
  24. /* this struct defines the way the registers are stored on the
  25. stack during a system call. */
  26. struct pt_regs {
  27. long d1;
  28. long d2;
  29. long d3;
  30. long d4;
  31. long d5;
  32. long a0;
  33. long a1;
  34. long a2;
  35. long d0;
  36. long orig_d0;
  37. long stkadj;
  38. #ifdef CONFIG_COLDFIRE
  39. unsigned format : 4; /* frame format specifier */
  40. unsigned vector : 12; /* vector offset */
  41. unsigned short sr;
  42. unsigned long pc;
  43. #else
  44. unsigned short sr;
  45. unsigned long pc;
  46. unsigned format : 4; /* frame format specifier */
  47. unsigned vector : 12; /* vector offset */
  48. #endif
  49. };
  50. /*
  51. * This is the extended stack used by signal handlers and the context
  52. * switcher: it's pushed after the normal "struct pt_regs".
  53. */
  54. struct switch_stack {
  55. unsigned long d6;
  56. unsigned long d7;
  57. unsigned long a3;
  58. unsigned long a4;
  59. unsigned long a5;
  60. unsigned long a6;
  61. unsigned long retpc;
  62. };
  63. /* Arbitrarily choose the same ptrace numbers as used by the Sparc code. */
  64. #define PTRACE_GETREGS 12
  65. #define PTRACE_SETREGS 13
  66. #define PTRACE_GETFPREGS 14
  67. #define PTRACE_SETFPREGS 15
  68. #define PTRACE_GET_THREAD_AREA 25
  69. #define PTRACE_GETFDPIC 31
  70. #define PTRACE_SINGLEBLOCK 33 /* resume execution until next branch */
  71. #define PTRACE_GETFDPIC_EXEC 0
  72. #define PTRACE_GETFDPIC_INTERP 1
  73. #endif /* __ASSEMBLY__ */
  74. #endif /* _UAPI_M68K_PTRACE_H */