From: Oleg Nesterov <oleg@tv-sign.ru>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Roland McGrath <roland@redhat.com>, linux-kernel@vger.kernel.org
Subject: [PATCH] wait_task_zombie: don't fight with non-existing race with a dying ptracee
Date: Fri, 17 Aug 2007 19:37:40 +0400 [thread overview]
Message-ID: <20070817153740.GA1098@tv-sign.ru> (raw)
(textually depends on wait_task_zombie-remove-unneeded-child-signal-check.patch)
The "p->exit_signal == -1 && p->ptrace == 0" check and the comment are bogus.
We already did exactly the same check in eligible_child(), we did not drop
tasklist_lock since then, and both variables need write_lock(tasklist) to be
changed.
Signed-off-by: Oleg Nesterov <oleg@tv-sign.ru>
--- t/kernel/exit.c~1_WTZ_NORACE 2007-08-17 17:31:59.000000000 +0400
+++ t/kernel/exit.c 2007-08-17 18:56:31.000000000 +0400
@@ -1210,13 +1210,6 @@ static int wait_task_zombie(struct task_
BUG_ON(state != EXIT_DEAD);
return 0;
}
- if (unlikely(p->exit_signal == -1 && p->ptrace == 0)) {
- /*
- * This can only happen in a race with a ptraced thread
- * dying on another processor.
- */
- return 0;
- }
/* traced means p->ptrace, but not vice versa */
traced = (p->real_parent != p->parent);
next reply other threads:[~2007-08-17 15:35 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-17 15:37 Oleg Nesterov [this message]
2007-08-17 20:04 ` Roland McGrath
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20070817153740.GA1098@tv-sign.ru \
--to=oleg@tv-sign.ru \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=roland@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®