diff options
-rw-r--r-- | kernel/ptrace.c | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/kernel/ptrace.c b/kernel/ptrace.c index 42ad8ae729a0..2f0f50b450a3 100644 --- a/kernel/ptrace.c +++ b/kernel/ptrace.c | |||
@@ -14,7 +14,6 @@ | |||
14 | #include <linux/mm.h> | 14 | #include <linux/mm.h> |
15 | #include <linux/highmem.h> | 15 | #include <linux/highmem.h> |
16 | #include <linux/pagemap.h> | 16 | #include <linux/pagemap.h> |
17 | #include <linux/smp_lock.h> | ||
18 | #include <linux/ptrace.h> | 17 | #include <linux/ptrace.h> |
19 | #include <linux/security.h> | 18 | #include <linux/security.h> |
20 | #include <linux/signal.h> | 19 | #include <linux/signal.h> |
@@ -666,10 +665,6 @@ SYSCALL_DEFINE4(ptrace, long, request, long, pid, long, addr, long, data) | |||
666 | struct task_struct *child; | 665 | struct task_struct *child; |
667 | long ret; | 666 | long ret; |
668 | 667 | ||
669 | /* | ||
670 | * This lock_kernel fixes a subtle race with suid exec | ||
671 | */ | ||
672 | lock_kernel(); | ||
673 | if (request == PTRACE_TRACEME) { | 668 | if (request == PTRACE_TRACEME) { |
674 | ret = ptrace_traceme(); | 669 | ret = ptrace_traceme(); |
675 | if (!ret) | 670 | if (!ret) |
@@ -703,7 +698,6 @@ SYSCALL_DEFINE4(ptrace, long, request, long, pid, long, addr, long, data) | |||
703 | out_put_task_struct: | 698 | out_put_task_struct: |
704 | put_task_struct(child); | 699 | put_task_struct(child); |
705 | out: | 700 | out: |
706 | unlock_kernel(); | ||
707 | return ret; | 701 | return ret; |
708 | } | 702 | } |
709 | 703 | ||
@@ -813,10 +807,6 @@ asmlinkage long compat_sys_ptrace(compat_long_t request, compat_long_t pid, | |||
813 | struct task_struct *child; | 807 | struct task_struct *child; |
814 | long ret; | 808 | long ret; |
815 | 809 | ||
816 | /* | ||
817 | * This lock_kernel fixes a subtle race with suid exec | ||
818 | */ | ||
819 | lock_kernel(); | ||
820 | if (request == PTRACE_TRACEME) { | 810 | if (request == PTRACE_TRACEME) { |
821 | ret = ptrace_traceme(); | 811 | ret = ptrace_traceme(); |
822 | goto out; | 812 | goto out; |
@@ -846,7 +836,6 @@ asmlinkage long compat_sys_ptrace(compat_long_t request, compat_long_t pid, | |||
846 | out_put_task_struct: | 836 | out_put_task_struct: |
847 | put_task_struct(child); | 837 | put_task_struct(child); |
848 | out: | 838 | out: |
849 | unlock_kernel(); | ||
850 | return ret; | 839 | return ret; |
851 | } | 840 | } |
852 | #endif /* CONFIG_COMPAT */ | 841 | #endif /* CONFIG_COMPAT */ |