[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200704192339.30783.rjw@sisk.pl>
Date: Thu, 19 Apr 2007 23:39:29 +0200
From: "Rafael J. Wysocki" <rjw@...k.pl>
To: ego@...ibm.com
Cc: Oleg Nesterov <oleg@...sign.ru>, linux-kernel@...r.kernel.org,
akpm@...ux-foundation.org, mingo@...e.hu, vatsa@...ibm.com,
paulmck@...ibm.com, pavel@....cz
Subject: Re: [RFC PATCH 1/2] Fix PF_NOFREEZE and freezeable race
Hi,
On Thursday, 19 April 2007 14:02, Gautham R Shenoy wrote:
> This patch fixes the race pointed out by Oleg Nesterov.
>
> * Freezer marks a thread as freezeable.
> * The thread now marks itself PF_NOFREEZE causing it to
> freeze on calling try_to_freeze(). Thus the task is frozen, even though
> it doesn't want to.
> * Subsequent thaw_processes() will also fail to thaw the task since it is
> marked PF_NOFREEZE.
>
> Avoid this problem by checking the current task's PF_NOFREEZE status in the
> refrigerator before marking current as frozen.
>
> Signed-off-by: Gautham R Shenoy <ego@...ibm.com>
Looks good, although I'm not sure if we don't need to call recalc_sigpending()
for tasks that turn out to be PF_NOFREEZE.
Greetings,
Rafael
-
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