diff options
Diffstat (limited to 'arch/s390/kernel/ptrace.c')
-rw-r--r-- | arch/s390/kernel/ptrace.c | 19 |
1 files changed, 4 insertions, 15 deletions
diff --git a/arch/s390/kernel/ptrace.c b/arch/s390/kernel/ptrace.c index f3ddd7ac06c5..a8738676b26c 100644 --- a/arch/s390/kernel/ptrace.c +++ b/arch/s390/kernel/ptrace.c | |||
@@ -339,24 +339,10 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
339 | int copied, ret; | 339 | int copied, ret; |
340 | 340 | ||
341 | switch (request) { | 341 | switch (request) { |
342 | case PTRACE_PEEKTEXT: | ||
343 | case PTRACE_PEEKDATA: | ||
344 | /* Remove high order bit from address (only for 31 bit). */ | ||
345 | addr &= PSW_ADDR_INSN; | ||
346 | /* read word at location addr. */ | ||
347 | return generic_ptrace_peekdata(child, addr, data); | ||
348 | |||
349 | case PTRACE_PEEKUSR: | 342 | case PTRACE_PEEKUSR: |
350 | /* read the word at location addr in the USER area. */ | 343 | /* read the word at location addr in the USER area. */ |
351 | return peek_user(child, addr, data); | 344 | return peek_user(child, addr, data); |
352 | 345 | ||
353 | case PTRACE_POKETEXT: | ||
354 | case PTRACE_POKEDATA: | ||
355 | /* Remove high order bit from address (only for 31 bit). */ | ||
356 | addr &= PSW_ADDR_INSN; | ||
357 | /* write the word at location addr. */ | ||
358 | return generic_ptrace_pokedata(child, addr, data); | ||
359 | |||
360 | case PTRACE_POKEUSR: | 346 | case PTRACE_POKEUSR: |
361 | /* write the word at location addr in the USER area */ | 347 | /* write the word at location addr in the USER area */ |
362 | return poke_user(child, addr, data); | 348 | return poke_user(child, addr, data); |
@@ -386,8 +372,11 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
386 | copied += sizeof(unsigned long); | 372 | copied += sizeof(unsigned long); |
387 | } | 373 | } |
388 | return 0; | 374 | return 0; |
375 | default: | ||
376 | /* Removing high order bit from addr (only for 31 bit). */ | ||
377 | addr &= PSW_ADDR_INSN; | ||
378 | return ptrace_request(child, request, addr, data); | ||
389 | } | 379 | } |
390 | return ptrace_request(child, request, addr, data); | ||
391 | } | 380 | } |
392 | 381 | ||
393 | #ifdef CONFIG_COMPAT | 382 | #ifdef CONFIG_COMPAT |