2009-03-16 20:07:39 +08:00
|
|
|
#ifndef _M68K_PTRACE_H
|
|
|
|
#define _M68K_PTRACE_H
|
|
|
|
|
2012-10-09 16:47:06 +08:00
|
|
|
#include <uapi/asm/ptrace.h>
|
2009-03-16 20:07:39 +08:00
|
|
|
|
|
|
|
#ifndef __ASSEMBLY__
|
|
|
|
|
|
|
|
#ifndef PS_S
|
|
|
|
#define PS_S (0x2000)
|
|
|
|
#define PS_M (0x1000)
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#define user_mode(regs) (!((regs)->sr & PS_S))
|
|
|
|
#define instruction_pointer(regs) ((regs)->pc)
|
|
|
|
#define profile_pc(regs) instruction_pointer(regs)
|
2012-09-17 00:06:34 +08:00
|
|
|
#define current_pt_regs() \
|
|
|
|
(struct pt_regs *)((char *)current_thread_info() + THREAD_SIZE) - 1
|
2012-11-19 01:50:10 +08:00
|
|
|
#define current_user_stack_pointer() rdusp()
|
2009-05-11 03:14:52 +08:00
|
|
|
|
|
|
|
#define arch_has_single_step() (1)
|
|
|
|
|
2009-07-07 13:54:54 +08:00
|
|
|
#ifdef CONFIG_MMU
|
2009-05-11 03:14:52 +08:00
|
|
|
#define arch_has_block_step() (1)
|
|
|
|
#endif
|
|
|
|
|
2009-03-16 20:07:39 +08:00
|
|
|
#endif /* __ASSEMBLY__ */
|
|
|
|
#endif /* _M68K_PTRACE_H */
|