diff options
author | Christoph Hellwig | 2010-03-10 15:22:44 -0800 |
---|---|---|
committer | Linus Torvalds | 2010-03-12 15:52:38 -0800 |
commit | b3c1e01a09d6af2dd7811a066ffcfc5171be2bed (patch) | |
tree | e59bb3618ed20fe05caba4c8cb7e292b7b2559b1 /arch/microblaze/kernel | |
parent | 7baab93f9297da3e42a8cecfbf91d5f22f415500 (diff) |
ptrace: use ptrace_request() in the remaining architectures
Use ptrace_request() in the three remaining architectures that didn't use it
(m68knommu, h8300, microblaze). This means:
- ptrace_request now handles PTRACE_{PEEK,POKE}{TEXT,DATA} and PTRACE_DETATCH
calls that were previously called directly, or in case of h8300 even open
coded.
- adds new support for PTRACE_SETOPTIONS/PTRACE_GETEVENTMSG/
PTRACE_GETSIGINFO/PTRACE_SETSIGINFO
Signed-off-by: Christoph Hellwig <hch@lst.de>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
Cc: Oleg Nesterov <oleg@redhat.com>
Cc: Michal Simek <monstr@monstr.eu>
Acked-by: Greg Ungerer <gerg@uclinux.org>
Acked-by: Roland McGrath <roland@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/microblaze/kernel')
-rw-r--r-- | arch/microblaze/kernel/ptrace.c | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/arch/microblaze/kernel/ptrace.c b/arch/microblaze/kernel/ptrace.c index 4b3ac32754de..8c21d8b3cb0c 100644 --- a/arch/microblaze/kernel/ptrace.c +++ b/arch/microblaze/kernel/ptrace.c @@ -78,26 +78,6 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) unsigned long copied; switch (request) { - case PTRACE_PEEKTEXT: /* read word at location addr. */ - case PTRACE_PEEKDATA: - pr_debug("PEEKTEXT/PEEKDATA at %08lX\n", addr); - copied = access_process_vm(child, addr, &val, sizeof(val), 0); - rval = -EIO; - if (copied != sizeof(val)) - break; - rval = put_user(val, (unsigned long *)data); - break; - - case PTRACE_POKETEXT: /* write the word at location addr. */ - case PTRACE_POKEDATA: - pr_debug("POKETEXT/POKEDATA to %08lX\n", addr); - rval = 0; - if (access_process_vm(child, addr, &data, sizeof(data), 1) - == sizeof(data)) - break; - rval = -EIO; - break; - /* Read/write the word at location ADDR in the registers. */ case PTRACE_PEEKUSR: case PTRACE_POKEUSR: @@ -167,13 +147,8 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) wake_up_process(child); break; - case PTRACE_DETACH: /* detach a process that was attached. */ - pr_debug("PTRACE_DETACH\n"); - rval = ptrace_detach(child, data); - break; default: - /* rval = ptrace_request(child, request, addr, data); noMMU */ - rval = -EIO; + rval = ptrace_request(child, request, addr, data); } return rval; } |