.. | .. |
---|
16 | 16 | #define user_mode(regs) (((regs)->sr & 0x40000000)==0) |
---|
17 | 17 | #define kernel_stack_pointer(_regs) ((unsigned long)(_regs)->regs[15]) |
---|
18 | 18 | |
---|
19 | | -#define GET_FP(regs) ((regs)->regs[14]) |
---|
20 | | -#define GET_USP(regs) ((regs)->regs[15]) |
---|
| 19 | +static inline unsigned long instruction_pointer(struct pt_regs *regs) |
---|
| 20 | +{ |
---|
| 21 | + return regs->pc; |
---|
| 22 | +} |
---|
| 23 | +static inline void instruction_pointer_set(struct pt_regs *regs, |
---|
| 24 | + unsigned long val) |
---|
| 25 | +{ |
---|
| 26 | + regs->pc = val; |
---|
| 27 | +} |
---|
| 28 | + |
---|
| 29 | +static inline unsigned long frame_pointer(struct pt_regs *regs) |
---|
| 30 | +{ |
---|
| 31 | + return regs->regs[14]; |
---|
| 32 | +} |
---|
| 33 | + |
---|
| 34 | +static inline unsigned long user_stack_pointer(struct pt_regs *regs) |
---|
| 35 | +{ |
---|
| 36 | + return regs->regs[15]; |
---|
| 37 | +} |
---|
| 38 | + |
---|
| 39 | +static inline void user_stack_pointer_set(struct pt_regs *regs, |
---|
| 40 | + unsigned long val) |
---|
| 41 | +{ |
---|
| 42 | + regs->regs[15] = val; |
---|
| 43 | +} |
---|
21 | 44 | |
---|
22 | 45 | #define arch_has_single_step() (1) |
---|
23 | 46 | |
---|
.. | .. |
---|
112 | 135 | |
---|
113 | 136 | return pc; |
---|
114 | 137 | } |
---|
115 | | -#define profile_pc profile_pc |
---|
116 | 138 | |
---|
117 | | -#include <asm-generic/ptrace.h> |
---|
118 | 139 | #endif /* __ASM_SH_PTRACE_H */ |
---|