summaryrefslogtreecommitdiff
path: root/init/main.c
diff options
context:
space:
mode:
authorPavel Emelyanov <xemul@openvz.org>2008-04-30 00:54:24 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2008-04-30 08:29:48 -0700
commit5cd204550b1a006f2b0c986b0e0f53220ebfd391 (patch)
treeee0f5e042072d4d2f4a3c6cd6e3a8b60676868ae /init/main.c
parentcb41d6d068716b2b3666925da34d3d7e658bf4f3 (diff)
Deprecate find_task_by_pid()
There are some places that are known to operate on tasks' global pids only: * the rest_init() call (called on boot) * the kgdb's getthread * the create_kthread() (since the kthread is run in init ns) So use the find_task_by_pid_ns(..., &init_pid_ns) there and schedule the find_task_by_pid for removal. [sukadev@us.ibm.com: Fix warning in kernel/pid.c] Signed-off-by: Pavel Emelyanov <xemul@openvz.org> Cc: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: Sukadev Bhattiprolu <sukadev@us.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'init/main.c')
-rw-r--r--init/main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/init/main.c b/init/main.c
index 1f4406477f83..dff253cfcd9f 100644
--- a/init/main.c
+++ b/init/main.c
@@ -459,7 +459,7 @@ static void noinline __init_refok rest_init(void)
kernel_thread(kernel_init, NULL, CLONE_FS | CLONE_SIGHAND);
numa_default_policy();
pid = kernel_thread(kthreadd, NULL, CLONE_FS | CLONE_FILES);
- kthreadd_task = find_task_by_pid(pid);
+ kthreadd_task = find_task_by_pid_ns(pid, &init_pid_ns);
unlock_kernel();
/*