diff options
author | David S. Miller <davem@davemloft.net> | 2008-02-07 01:01:01 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-02-07 05:59:08 -0500 |
commit | 38282764e3e76aa02c071af4673e6b6320e426ad (patch) | |
tree | 7d3bf23089142c3f12ec5eca00a17cb1f33518e1 /arch/sparc | |
parent | 8e3fe806e50d48d875bb56793ca3f984cba6c0db (diff) |
[SPARC]: Kill DEBUG_PTRACE code.
It has long exceeded it's usefulness.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'arch/sparc')
-rw-r--r-- | arch/sparc/kernel/ptrace.c | 46 |
1 files changed, 0 insertions, 46 deletions
diff --git a/arch/sparc/kernel/ptrace.c b/arch/sparc/kernel/ptrace.c index c1e7e6ae7c6..0619958ecfd 100644 --- a/arch/sparc/kernel/ptrace.c +++ b/arch/sparc/kernel/ptrace.c | |||
@@ -236,19 +236,6 @@ failure: | |||
236 | } | 236 | } |
237 | 237 | ||
238 | /* #define ALLOW_INIT_TRACING */ | 238 | /* #define ALLOW_INIT_TRACING */ |
239 | /* #define DEBUG_PTRACE */ | ||
240 | |||
241 | #ifdef DEBUG_PTRACE | ||
242 | char *pt_rq [] = { | ||
243 | /* 0 */ "TRACEME", "PEEKTEXT", "PEEKDATA", "PEEKUSR", | ||
244 | /* 4 */ "POKETEXT", "POKEDATA", "POKEUSR", "CONT", | ||
245 | /* 8 */ "KILL", "SINGLESTEP", "SUNATTACH", "SUNDETACH", | ||
246 | /* 12 */ "GETREGS", "SETREGS", "GETFPREGS", "SETFPREGS", | ||
247 | /* 16 */ "READDATA", "WRITEDATA", "READTEXT", "WRITETEXT", | ||
248 | /* 20 */ "GETFPAREGS", "SETFPAREGS", "unknown", "unknown", | ||
249 | /* 24 */ "SYSCALL", "" | ||
250 | }; | ||
251 | #endif | ||
252 | 239 | ||
253 | /* | 240 | /* |
254 | * Called by kernel/ptrace.c when detaching.. | 241 | * Called by kernel/ptrace.c when detaching.. |
@@ -552,23 +539,6 @@ asmlinkage void do_ptrace(struct pt_regs *regs) | |||
552 | int ret; | 539 | int ret; |
553 | 540 | ||
554 | lock_kernel(); | 541 | lock_kernel(); |
555 | #ifdef DEBUG_PTRACE | ||
556 | { | ||
557 | char *s; | ||
558 | |||
559 | if ((request >= 0) && (request <= 24)) | ||
560 | s = pt_rq [request]; | ||
561 | else | ||
562 | s = "unknown"; | ||
563 | |||
564 | if (request == PTRACE_POKEDATA && data == 0x91d02001){ | ||
565 | printk ("do_ptrace: breakpoint pid=%d, addr=%08lx addr2=%08lx\n", | ||
566 | pid, addr, addr2); | ||
567 | } else | ||
568 | printk("do_ptrace: rq=%s(%d) pid=%d addr=%08lx data=%08lx addr2=%08lx\n", | ||
569 | s, (int) request, (int) pid, addr, data, addr2); | ||
570 | } | ||
571 | #endif | ||
572 | 542 | ||
573 | if (request == PTRACE_TRACEME) { | 543 | if (request == PTRACE_TRACEME) { |
574 | ret = ptrace_traceme(); | 544 | ret = ptrace_traceme(); |
@@ -650,9 +620,6 @@ asmlinkage void do_ptrace(struct pt_regs *regs) | |||
650 | for(rval = 1; rval < 16; rval++) | 620 | for(rval = 1; rval < 16; rval++) |
651 | __put_user(cregs->u_regs[rval], (&pregs->u_regs[rval - 1])); | 621 | __put_user(cregs->u_regs[rval], (&pregs->u_regs[rval - 1])); |
652 | pt_succ_return(regs, 0); | 622 | pt_succ_return(regs, 0); |
653 | #ifdef DEBUG_PTRACE | ||
654 | printk ("PC=%x nPC=%x o7=%x\n", cregs->pc, cregs->npc, cregs->u_regs [15]); | ||
655 | #endif | ||
656 | goto out_tsk; | 623 | goto out_tsk; |
657 | } | 624 | } |
658 | 625 | ||
@@ -801,12 +768,6 @@ asmlinkage void do_ptrace(struct pt_regs *regs) | |||
801 | clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); | 768 | clear_tsk_thread_flag(child, TIF_SYSCALL_TRACE); |
802 | 769 | ||
803 | child->exit_code = data; | 770 | child->exit_code = data; |
804 | #ifdef DEBUG_PTRACE | ||
805 | printk("CONT: %s [%d]: set exit_code = %x %lx %lx\n", | ||
806 | child->comm, child->pid, child->exit_code, | ||
807 | child->thread.kregs->pc, | ||
808 | child->thread.kregs->npc); | ||
809 | #endif | ||
810 | wake_up_process(child); | 771 | wake_up_process(child); |
811 | pt_succ_return(regs, 0); | 772 | pt_succ_return(regs, 0); |
812 | goto out_tsk; | 773 | goto out_tsk; |
@@ -858,9 +819,6 @@ out: | |||
858 | 819 | ||
859 | asmlinkage void syscall_trace(void) | 820 | asmlinkage void syscall_trace(void) |
860 | { | 821 | { |
861 | #ifdef DEBUG_PTRACE | ||
862 | printk("%s [%d]: syscall_trace\n", current->comm, current->pid); | ||
863 | #endif | ||
864 | if (!test_thread_flag(TIF_SYSCALL_TRACE)) | 822 | if (!test_thread_flag(TIF_SYSCALL_TRACE)) |
865 | return; | 823 | return; |
866 | if (!(current->ptrace & PT_PTRACED)) | 824 | if (!(current->ptrace & PT_PTRACED)) |
@@ -873,10 +831,6 @@ asmlinkage void syscall_trace(void) | |||
873 | * for normal use. strace only continues with a signal if the | 831 | * for normal use. strace only continues with a signal if the |
874 | * stopping signal is not SIGTRAP. -brl | 832 | * stopping signal is not SIGTRAP. -brl |
875 | */ | 833 | */ |
876 | #ifdef DEBUG_PTRACE | ||
877 | printk("%s [%d]: syscall_trace exit= %x\n", current->comm, | ||
878 | current->pid, current->exit_code); | ||
879 | #endif | ||
880 | if (current->exit_code) { | 834 | if (current->exit_code) { |
881 | send_sig (current->exit_code, current, 1); | 835 | send_sig (current->exit_code, current, 1); |
882 | current->exit_code = 0; | 836 | current->exit_code = 0; |