aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/include/asm/ptrace.h
diff options
context:
space:
mode:
authorAlexey Kardashevskiy <aik@ozlabs.ru>2013-02-14 12:44:23 -0500
committerMichael Ellerman <michael@ellerman.id.au>2013-04-17 23:03:57 -0400
commitee4a3916614829914830bc4371358f4d4a63c4d9 (patch)
treeba1c65ba0a58933b8d9d43fe0374bdbc775338ad /arch/powerpc/include/asm/ptrace.h
parent3cc33d50f52521760da29ebd9db239741da7f21a (diff)
powerpc: fixing ptrace_get_reg to return an error
Currently ptrace_get_reg returns error as a value what make impossible to tell whether it is a correct value or error code. The patch adds a parameter which points to the real return data and returns an error code. As get_user_msr() never fails and it is used in multiple places so it has not been changed by this patch. Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru> Acked-by: Michael Neuling <mikey@neuling.org> Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/include/asm/ptrace.h')
-rw-r--r--arch/powerpc/include/asm/ptrace.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/powerpc/include/asm/ptrace.h b/arch/powerpc/include/asm/ptrace.h
index 5f995681bc1d..becc08e6a65c 100644
--- a/arch/powerpc/include/asm/ptrace.h
+++ b/arch/powerpc/include/asm/ptrace.h
@@ -92,7 +92,8 @@ static inline long regs_return_value(struct pt_regs *regs)
92 } while(0) 92 } while(0)
93 93
94struct task_struct; 94struct task_struct;
95extern unsigned long ptrace_get_reg(struct task_struct *task, int regno); 95extern int ptrace_get_reg(struct task_struct *task, int regno,
96 unsigned long *data);
96extern int ptrace_put_reg(struct task_struct *task, int regno, 97extern int ptrace_put_reg(struct task_struct *task, int regno,
97 unsigned long data); 98 unsigned long data);
98 99