ptrace: remove PT_DTRACE from avr32, mn10300, parisc, s390, sh, xtensa
authorOleg Nesterov <oleg@redhat.com>
Wed, 17 Jun 2009 23:27:25 +0000 (16:27 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 18 Jun 2009 20:03:48 +0000 (13:03 -0700)
avr32, mn10300, parisc, s390, sh, xtensa:

They never set PT_DTRACE, but clear it after do_execve().

Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Cc: David Howells <dhowells@redhat.com>
Acked-by: Kyle McMartin <kyle@mcmartin.ca>
Cc: Grant Grundler <grundler@parisc-linux.org>
Cc: Matthew Wilcox <matthew@wil.cx>
Acked-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Acked-by: Paul Mundt <lethal@linux-sh.org>
Acked-by: Chris Zankel <chris@zankel.net>
Acked-by: Roland McGrath <roland@redhat.com>
Acked-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/avr32/kernel/process.c
arch/mn10300/kernel/process.c
arch/parisc/hpux/fs.c
arch/parisc/kernel/process.c
arch/parisc/kernel/sys_parisc32.c
arch/s390/kernel/compat_linux.c
arch/s390/kernel/process.c
arch/sh/kernel/process_32.c
arch/sh/kernel/process_64.c
arch/xtensa/kernel/process.c

index 1bbe1da54869bd2192f6a9f4638bdf20e468b983..93c0342530a0d02beb47f61f8e7e8a260fe67764 100644 (file)
@@ -394,8 +394,6 @@ asmlinkage int sys_execve(char __user *ufilename, char __user *__user *uargv,
                goto out;
 
        error = do_execve(filename, uargv, uenvp, regs);
-       if (error == 0)
-               current->ptrace &= ~PT_DTRACE;
        putname(filename);
 
 out:
index 234cf344cdceb1e39f550947ddae8d2331435d63..892cce82867e3d72c60c4846c2be6b2f0310231a 100644 (file)
@@ -281,9 +281,6 @@ asmlinkage long sys_execve(char __user *name,
        error = PTR_ERR(filename);
        if (!IS_ERR(filename)) {
                error = do_execve(filename, argv, envp, __frame);
-               if (error == 0)
-                       current->ptrace &= ~PT_DTRACE;
-
                putname(filename);
        }
 
index 5cbe9f9e5d9ef71908ee166ec19932a6fd6f2de8..54075360a8fdb5cd43c0abee9669ae4ac9bce7fc 100644 (file)
@@ -44,11 +44,6 @@ int hpux_execve(struct pt_regs *regs)
        error = do_execve(filename, (char __user * __user *) regs->gr[25],
                (char __user * __user *) regs->gr[24], regs);
 
-       if (error == 0) {
-               task_lock(current);
-               current->ptrace &= ~PT_DTRACE;
-               task_unlock(current);
-       }
        putname(filename);
 
 out:
index 6f69101f90bb24df54b99259a5419f84a76dbb35..61c07078c072d69c60769e4273339c3ac8fe8d62 100644 (file)
@@ -349,11 +349,6 @@ asmlinkage int sys_execve(struct pt_regs *regs)
                goto out;
        error = do_execve(filename, (char __user * __user *) regs->gr[25],
                (char __user * __user *) regs->gr[24], regs);
-       if (error == 0) {
-               task_lock(current);
-               current->ptrace &= ~PT_DTRACE;
-               task_unlock(current);
-       }
        putname(filename);
 out:
 
index 0838155b7a88229df24188a9f0dc74b2facf1162..1adb40c8166965ae1c397abe272187a42639fcf6 100644 (file)
@@ -77,11 +77,6 @@ asmlinkage int sys32_execve(struct pt_regs *regs)
                goto out;
        error = compat_do_execve(filename, compat_ptr(regs->gr[25]),
                                 compat_ptr(regs->gr[24]), regs);
-       if (error == 0) {
-               task_lock(current);
-               current->ptrace &= ~PT_DTRACE;
-               task_unlock(current);
-       }
        putname(filename);
 out:
 
index 002c70d3cb7512c8ce04a9de258fe71603af3675..9ab188d67a3d872df26095cf15e530afaed2a31d 100644 (file)
@@ -461,9 +461,6 @@ asmlinkage long sys32_execve(void)
                result = rc;
                goto out_putname;
        }
-       task_lock(current);
-       current->ptrace &= ~PT_DTRACE;
-       task_unlock(current);
        current->thread.fp_regs.fpc=0;
        asm volatile("sfpc %0,0" : : "d" (0));
        result = regs->gprs[2];
index 355f7a30c3f11c7cdc8a1eaddc77c41a42e9808b..5a43f27eec13eafd4ecf36d4c5c82fd4f533e349 100644 (file)
@@ -266,9 +266,6 @@ SYSCALL_DEFINE0(vfork)
 
 asmlinkage void execve_tail(void)
 {
-       task_lock(current);
-       current->ptrace &= ~PT_DTRACE;
-       task_unlock(current);
        current->thread.fp_regs.fpc = 0;
        if (MACHINE_HAS_IEEE)
                asm volatile("sfpc %0,%0" : : "d" (0));
index 9289ede29c7b405fa02dc2b71ebf655d1def9ef0..601bbc0ec74e2739210cd0e700b4c4876d3cd82a 100644 (file)
@@ -367,11 +367,6 @@ asmlinkage int sys_execve(char __user *ufilename, char __user * __user *uargv,
                goto out;
 
        error = do_execve(filename, uargv, uenvp, regs);
-       if (error == 0) {
-               task_lock(current);
-               current->ptrace &= ~PT_DTRACE;
-               task_unlock(current);
-       }
        putname(filename);
 out:
        return error;
index 96be839040f88f4fe5e606af0eb06ce7d0986626..3826773496d810ba979178343e4c14d9298bc928 100644 (file)
@@ -529,11 +529,6 @@ asmlinkage int sys_execve(char *ufilename, char **uargv,
                          (char __user * __user *)uargv,
                          (char __user * __user *)uenvp,
                          pregs);
-       if (error == 0) {
-               task_lock(current);
-               current->ptrace &= ~PT_DTRACE;
-               task_unlock(current);
-       }
        putname(filename);
 out:
        return error;
index 031f36685710d087d4b5b7f8426542ea97bc3178..e1a04a346e75811cde445b4ad4bce4cd0c679cd9 100644 (file)
@@ -331,11 +331,6 @@ long xtensa_execve(char __user *name, char __user * __user *argv,
        if (IS_ERR(filename))
                goto out;
        error = do_execve(filename, argv, envp, regs);
-       if (error == 0) {
-               task_lock(current);
-               current->ptrace &= ~PT_DTRACE;
-               task_unlock(current);
-       }
        putname(filename);
 out:
        return error;