Commit 6d110da8c3c62167c54eb5e32bb80916a1a23362
Committed by
Paul Mackerras
1 parent
abd0650541
Exists in
master
and in
7 other branches
[POWERPC] powerpc: ptrace can set DABR on both 32 and 64 bits
Allow ptrace to set dabr in the thread structure for both 32 and 64 bits, though only 64 bits actually uses that field, it's actually defined in both. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
Showing 1 changed file with 0 additions and 4 deletions Side-by-side Diff
arch/powerpc/kernel/ptrace.c
... | ... | @@ -286,7 +286,6 @@ |
286 | 286 | clear_tsk_thread_flag(task, TIF_SINGLESTEP); |
287 | 287 | } |
288 | 288 | |
289 | -#ifdef CONFIG_PPC64 | |
290 | 289 | static int ptrace_set_debugreg(struct task_struct *task, unsigned long addr, |
291 | 290 | unsigned long data) |
292 | 291 | { |
... | ... | @@ -305,7 +304,6 @@ |
305 | 304 | task->thread.dabr = data; |
306 | 305 | return 0; |
307 | 306 | } |
308 | -#endif | |
309 | 307 | |
310 | 308 | /* |
311 | 309 | * Called by kernel/ptrace.c when detaching.. |
... | ... | @@ -503,7 +501,6 @@ |
503 | 501 | break; |
504 | 502 | } |
505 | 503 | |
506 | -#ifdef CONFIG_PPC64 | |
507 | 504 | case PTRACE_GET_DEBUGREG: { |
508 | 505 | ret = -EINVAL; |
509 | 506 | /* We only support one DABR and no IABRS at the moment */ |
... | ... | @@ -517,7 +514,6 @@ |
517 | 514 | case PTRACE_SET_DEBUGREG: |
518 | 515 | ret = ptrace_set_debugreg(child, addr, data); |
519 | 516 | break; |
520 | -#endif | |
521 | 517 | |
522 | 518 | case PTRACE_DETACH: |
523 | 519 | ret = ptrace_detach(child, data); |