diff options
author | Alexey Dobriyan <adobriyan@gmail.com> | 2007-07-17 04:03:43 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-07-17 10:23:03 -0700 |
commit | 7664732315c97f48dba9d1e7339ad16fc5a320ac (patch) | |
tree | 1eb9639b0fbe3f24341cecf1dafcae192cb7bde7 /arch/m32r | |
parent | bcdcd8e725b923ad7c0de809680d5d5658a7bf8c (diff) | |
download | op-kernel-dev-7664732315c97f48dba9d1e7339ad16fc5a320ac.zip op-kernel-dev-7664732315c97f48dba9d1e7339ad16fc5a320ac.tar.gz |
PTRACE_PEEKDATA consolidation
Identical implementations of PTRACE_PEEKDATA go into generic_ptrace_peekdata()
function.
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: <linux-arch@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/m32r')
-rw-r--r-- | arch/m32r/kernel/ptrace.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/arch/m32r/kernel/ptrace.c b/arch/m32r/kernel/ptrace.c index 5f02b31..01a1c9a 100644 --- a/arch/m32r/kernel/ptrace.c +++ b/arch/m32r/kernel/ptrace.c @@ -595,7 +595,6 @@ void ptrace_disable(struct task_struct *child) static int do_ptrace(long request, struct task_struct *child, long addr, long data) { - unsigned long tmp; int ret; switch (request) { @@ -604,11 +603,7 @@ do_ptrace(long request, struct task_struct *child, long addr, long data) */ case PTRACE_PEEKTEXT: case PTRACE_PEEKDATA: - ret = access_process_vm(child, addr, &tmp, sizeof(tmp), 0); - if (ret == sizeof(tmp)) - ret = put_user(tmp,(unsigned long __user *) data); - else - ret = -EIO; + ret = generic_ptrace_peekdata(child, addr, data); break; /* |