summaryrefslogtreecommitdiffstats
path: root/kernel/exit.c
diff options
context:
space:
mode:
authorEric W. Biederman <ebiederm@xmission.com>2012-08-01 15:03:42 -0700
committerEric W. Biederman <ebiederm@xmission.com>2012-11-19 05:59:12 -0800
commitaf4b8a83add95ef40716401395b44a1b579965f4 (patch)
tree2f3f606b7327f74c1c1beb8a75886318c51c838a /kernel/exit.c
parent5e1182deb81ae8c68494017c4a8a71811659c870 (diff)
downloadlinux-af4b8a83add95ef40716401395b44a1b579965f4.tar.gz
linux-af4b8a83add95ef40716401395b44a1b579965f4.tar.bz2
linux-af4b8a83add95ef40716401395b44a1b579965f4.zip
pidns: Wait in zap_pid_ns_processes until pid_ns->nr_hashed == 1
Looking at pid_ns->nr_hashed is a bit simpler and it works for disjoint process trees that an unshare or a join of a pid_namespace may create. Acked-by: "Serge E. Hallyn" <serge@hallyn.com> Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Diffstat (limited to 'kernel/exit.c')
-rw-r--r--kernel/exit.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/kernel/exit.c b/kernel/exit.c
index 346616c0092c..d7fe58db4527 100644
--- a/kernel/exit.c
+++ b/kernel/exit.c
@@ -72,18 +72,6 @@ static void __unhash_process(struct task_struct *p, bool group_dead)
list_del_rcu(&p->tasks);
list_del_init(&p->sibling);
__this_cpu_dec(process_counts);
- /*
- * If we are the last child process in a pid namespace to be
- * reaped, notify the reaper sleeping zap_pid_ns_processes().
- */
- if (IS_ENABLED(CONFIG_PID_NS)) {
- struct task_struct *parent = p->real_parent;
-
- if ((task_active_pid_ns(parent)->child_reaper == parent) &&
- list_empty(&parent->children) &&
- (parent->flags & PF_EXITING))
- wake_up_process(parent);
- }
}
list_del_rcu(&p->thread_group);
}