The patch titled Use write_trylock_irqsave in ptrace_attach has been added to the -mm tree. Its filename is use-write_trylock_irqsave-in-ptrace_attach.patch *** Remember to use Documentation/SubmitChecklist when testing your code *** See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this ------------------------------------------------------ Subject: Use write_trylock_irqsave in ptrace_attach From: Sripathi Kodi <sripathik@xxxxxxxxxx> This patch makes ptrace_attach use write_trylock_irqsave(). Signed-off-by: Sripathi Kodi <sripathik@xxxxxxxxxx> Cc: Ingo Molnar <mingo@xxxxxxx> Cc: Oleg Nesterov <oleg@xxxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- kernel/ptrace.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff -puN kernel/ptrace.c~use-write_trylock_irqsave-in-ptrace_attach kernel/ptrace.c --- a/kernel/ptrace.c~use-write_trylock_irqsave-in-ptrace_attach +++ a/kernel/ptrace.c @@ -160,6 +160,7 @@ int ptrace_may_attach(struct task_struct int ptrace_attach(struct task_struct *task) { int retval; + unsigned long flags = 0; retval = -EPERM; if (task->pid <= 1) @@ -178,9 +179,7 @@ repeat: * cpu's that may have task_lock). */ task_lock(task); - local_irq_disable(); - if (!write_trylock(&tasklist_lock)) { - local_irq_enable(); + if (!write_trylock_irqsave(&tasklist_lock, flags)) { task_unlock(task); do { cpu_relax(); @@ -208,7 +207,7 @@ repeat: force_sig_specific(SIGSTOP, task); bad: - write_unlock_irq(&tasklist_lock); + write_unlock_irqrestore(&tasklist_lock, flags); task_unlock(task); out: return retval; _ Patches currently in -mm which might be from sripathik@xxxxxxxxxx are introduce-write_trylock_irqsave.patch use-write_trylock_irqsave-in-ptrace_attach.patch use-write_trylock_irqsave-in-ptrace_attach-fix.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html