diff options
author | Al Viro <viro@ftp.linux.org.uk> | 2006-01-12 04:06:03 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-01-12 12:08:58 -0500 |
commit | 95ca0dc603ab58f3e4c5a1c23f675bd1f5b5fef3 (patch) | |
tree | 367ddcc3858b9c3e852ea2f6bafaffd43424c9e5 /arch/cris/arch-v32/kernel/ptrace.c | |
parent | 0cec6fd1370807f98934e84c9e6147335b81d8a5 (diff) |
[PATCH] cris: task_pt_regs()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'arch/cris/arch-v32/kernel/ptrace.c')
-rw-r--r-- | arch/cris/arch-v32/kernel/ptrace.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/cris/arch-v32/kernel/ptrace.c b/arch/cris/arch-v32/kernel/ptrace.c index 5528b83a622b..82cf2e3624a4 100644 --- a/arch/cris/arch-v32/kernel/ptrace.c +++ b/arch/cris/arch-v32/kernel/ptrace.c | |||
@@ -46,7 +46,7 @@ long get_reg(struct task_struct *task, unsigned int regno) | |||
46 | unsigned long ret; | 46 | unsigned long ret; |
47 | 47 | ||
48 | if (regno <= PT_EDA) | 48 | if (regno <= PT_EDA) |
49 | ret = ((unsigned long *)user_regs(task->thread_info))[regno]; | 49 | ret = ((unsigned long *)task_pt_regs(task))[regno]; |
50 | else if (regno == PT_USP) | 50 | else if (regno == PT_USP) |
51 | ret = task->thread.usp; | 51 | ret = task->thread.usp; |
52 | else if (regno == PT_PPC) | 52 | else if (regno == PT_PPC) |
@@ -65,13 +65,13 @@ long get_reg(struct task_struct *task, unsigned int regno) | |||
65 | int put_reg(struct task_struct *task, unsigned int regno, unsigned long data) | 65 | int put_reg(struct task_struct *task, unsigned int regno, unsigned long data) |
66 | { | 66 | { |
67 | if (regno <= PT_EDA) | 67 | if (regno <= PT_EDA) |
68 | ((unsigned long *)user_regs(task->thread_info))[regno] = data; | 68 | ((unsigned long *)task_pt_regs(task))[regno] = data; |
69 | else if (regno == PT_USP) | 69 | else if (regno == PT_USP) |
70 | task->thread.usp = data; | 70 | task->thread.usp = data; |
71 | else if (regno == PT_PPC) { | 71 | else if (regno == PT_PPC) { |
72 | /* Write pseudo-PC to ERP only if changed. */ | 72 | /* Write pseudo-PC to ERP only if changed. */ |
73 | if (data != get_pseudo_pc(task)) | 73 | if (data != get_pseudo_pc(task)) |
74 | ((unsigned long *)user_regs(task->thread_info))[PT_ERP] = data; | 74 | task_pt_regs(task)->erp = data; |
75 | } else if (regno <= PT_MAX) | 75 | } else if (regno <= PT_MAX) |
76 | return put_debugreg(task->pid, regno, data); | 76 | return put_debugreg(task->pid, regno, data); |
77 | else | 77 | else |