mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
kill task_detached()
Upadate the last user of task_detached(), wait_task_zombie(), to use thread_group_leader() and kill task_detached(). Signed-off-by: Oleg Nesterov <oleg@redhat.com> Reviewed-by: Tejun Heo <tj@kernel.org>
This commit is contained in:
parent
0976a03e5c
commit
e550f14dc6
2 changed files with 2 additions and 8 deletions
|
@ -189,7 +189,6 @@ repeat:
|
|||
zap_leader = 0;
|
||||
leader = p->group_leader;
|
||||
if (leader != p && thread_group_empty(leader) && leader->exit_state == EXIT_ZOMBIE) {
|
||||
BUG_ON(task_detached(leader));
|
||||
/*
|
||||
* If we were the last child thread and the leader has
|
||||
* exited already, and the leader's parent ignores SIGCHLD,
|
||||
|
@ -1231,9 +1230,9 @@ static int wait_task_zombie(struct wait_opts *wo, struct task_struct *p)
|
|||
traced = ptrace_reparented(p);
|
||||
/*
|
||||
* It can be ptraced but not reparented, check
|
||||
* !task_detached() to filter out sub-threads.
|
||||
* thread_group_leader() to filter out sub-threads.
|
||||
*/
|
||||
if (likely(!traced) && likely(!task_detached(p))) {
|
||||
if (likely(!traced) && thread_group_leader(p)) {
|
||||
struct signal_struct *psig;
|
||||
struct signal_struct *sig;
|
||||
unsigned long maxrss;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue