10 #include <linux/kernel.h>
11 #include <linux/sched.h>
14 #include <linux/errno.h>
15 #include <linux/ptrace.h>
18 #include <linux/personality.h>
21 #include <linux/signal.h>
23 #include <asm/uaccess.h>
24 #include <asm/pgtable.h>
25 #include <asm/processor.h>
26 #include <asm/asm-offsets.h>
29 #define USER_PSW_BITS (PSW_N | PSW_V | PSW_CB)
113 unsigned long addr,
unsigned long data)
123 if ((addr & (
sizeof(
unsigned long)-1)) ||
124 addr >=
sizeof(
struct pt_regs))
154 if ((addr & (
sizeof(
unsigned long)-1)) ||
155 addr >=
sizeof(
struct pt_regs))
157 if ((addr >= PT_GR1 && addr <= PT_GR31) ||
158 addr == PT_IAOQ0 || addr == PT_IAOQ1 ||
159 (addr >= PT_FR0 && addr <= PT_FR31 + 4) ||
161 *(
unsigned long *) ((
char *)
task_regs(child) +
addr) = data;
192 else if (offset <= 32*4)
193 return offset * 2 + 4;
194 else if (offset <= 32*4+32*8)
195 return offset + 32*4;
196 else if (offset <
sizeof(
struct pt_regs)/2 + 32*4)
197 return offset * 2 + 4 - 32*8;
213 addr = translate_usr_offset(addr);
214 if (addr >=
sizeof(
struct pt_regs))
240 addr = translate_usr_offset(addr);
241 if (addr >=
sizeof(
struct pt_regs))
243 if (addr >= PT_FR0 && addr <= PT_FR31 + 4) {
248 else if ((addr >= PT_GR1+4 && addr <= PT_GR31+4) ||
249 addr == PT_IAOQ0+4 || addr == PT_IAOQ1+4 ||
260 ret = compat_ptrace_request(child, request, addr, data);
271 tracehook_report_syscall_entry(regs))
283 tracehook_report_syscall_exit(regs, stepping);