[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20101128190741.GA12896@redhat.com>
Date: Sun, 28 Nov 2010 20:07:42 +0100
From: Oleg Nesterov <oleg@...hat.com>
To: Tejun Heo <tj@...nel.org>
Cc: roland@...hat.com, linux-kernel@...r.kernel.org,
torvalds@...ux-foundation.org, akpm@...ux-foundation.org
Subject: Re: [PATCH UPDATED 06/14] signal: use GROUP_STOP_PENDING to avoid
stopping multiple times for a single group stop
On 11/27, Tejun Heo wrote:
>
> static int recalc_sigpending_tsk(struct task_struct *t)
> {
> - if (t->signal->group_stop_count > 0 ||
> + if ((t->group_stop & GROUP_STOP_PENDING) ||
OK, this makes the intent clear.
> @@ -732,6 +732,9 @@ static int prepare_signal(int sig, struct task_struct *p, int from_ancestor_ns)
> t = p;
> do {
> unsigned int state;
> +
> + t->group_stop = 0;
> +
Yes.
But, afaics, this is not enough. Say, what about zap_other_threads() ?
We shouldn't allow sub-threads to stop in this case.
Basically, every time we clear ->group_stop_count we should also reset
->group_stop for every thread. Fortunately, every time we already do
while_each_thread().
Oleg.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists