kgdb.h 1014 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef _SPARC_KGDB_H
  3. #define _SPARC_KGDB_H
  4. #ifdef CONFIG_SPARC32
  5. #define BUFMAX 2048
  6. #else
  7. #define BUFMAX 4096
  8. #endif
  9. enum regnames {
  10. GDB_G0, GDB_G1, GDB_G2, GDB_G3, GDB_G4, GDB_G5, GDB_G6, GDB_G7,
  11. GDB_O0, GDB_O1, GDB_O2, GDB_O3, GDB_O4, GDB_O5, GDB_SP, GDB_O7,
  12. GDB_L0, GDB_L1, GDB_L2, GDB_L3, GDB_L4, GDB_L5, GDB_L6, GDB_L7,
  13. GDB_I0, GDB_I1, GDB_I2, GDB_I3, GDB_I4, GDB_I5, GDB_FP, GDB_I7,
  14. GDB_F0,
  15. GDB_F31 = GDB_F0 + 31,
  16. #ifdef CONFIG_SPARC32
  17. GDB_Y, GDB_PSR, GDB_WIM, GDB_TBR, GDB_PC, GDB_NPC,
  18. GDB_FSR, GDB_CSR,
  19. #else
  20. GDB_F32 = GDB_F0 + 32,
  21. GDB_F62 = GDB_F32 + 15,
  22. GDB_PC, GDB_NPC, GDB_STATE, GDB_FSR, GDB_FPRS, GDB_Y,
  23. #endif
  24. };
  25. #ifdef CONFIG_SPARC32
  26. #define NUMREGBYTES ((GDB_CSR + 1) * 4)
  27. #else
  28. #define NUMREGBYTES ((GDB_Y + 1) * 8)
  29. #endif
  30. struct pt_regs;
  31. asmlinkage void kgdb_trap(unsigned long trap_level, struct pt_regs *regs);
  32. void arch_kgdb_breakpoint(void);
  33. #define BREAK_INSTR_SIZE 4
  34. #define CACHE_FLUSH_IS_SAFE 1
  35. #endif /* _SPARC_KGDB_H */