[PATCH] elf_fdpic_core_dump: don't take tasklist_lock
commitbce9a234ce7d8dddbfcec28e37ea58b5d8f6003d
authorOleg Nesterov <oleg@tv-sign.ru>
Fri, 29 Sep 2006 09:00:25 +0000 (29 02:00 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Fri, 29 Sep 2006 16:18:14 +0000 (29 09:18 -0700)
treec5bdbedb08abab4673f1cdab12b7358facc247db
parent486ccb05fdbb7ca79784fdf0d07d2a86de48cf05
[PATCH] elf_fdpic_core_dump: don't take tasklist_lock

do_each_thread() is rcu-safe, and all tasks which use this ->mm must sleep
in wait_for_completion(&mm->core_done) at this point, so we can use RCU
locks.

Also, remove unneeded INIT_LIST_HEAD(new) before list_add(new, head).

Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
Acked-By: David Howells <dhowells@redhat.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/binfmt_elf_fdpic.c