ptrace.h 643 B

1234567891011121314151617181920212223242526272829
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef _M68K_PTRACE_H
  3. #define _M68K_PTRACE_H
  4. #include <uapi/asm/ptrace.h>
  5. #ifndef __ASSEMBLY__
  6. #ifndef PS_S
  7. #define PS_S (0x2000)
  8. #define PS_M (0x1000)
  9. #endif
  10. #define user_mode(regs) (!((regs)->sr & PS_S))
  11. #define instruction_pointer(regs) ((regs)->pc)
  12. #define profile_pc(regs) instruction_pointer(regs)
  13. #define current_pt_regs() \
  14. (struct pt_regs *)((char *)current_thread_info() + THREAD_SIZE) - 1
  15. #define current_user_stack_pointer() rdusp()
  16. #define arch_has_single_step() (1)
  17. #ifdef CONFIG_MMU
  18. #define arch_has_block_step() (1)
  19. #endif
  20. #endif /* __ASSEMBLY__ */
  21. #endif /* _M68K_PTRACE_H */