lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110828180901.GD27032@redhat.com>
Date:	Sun, 28 Aug 2011 20:09:01 +0200
From:	Oleg Nesterov <oleg@...hat.com>
To:	Tejun Heo <tj@...nel.org>
Cc:	rjw@...k.pl, paul@...lmenage.org, linux-kernel@...r.kernel.org,
	arnd@...db.de
Subject: Re: [PATCH 12/16] freezer: clean up freeze_processes() failure path

On 08/19, Tejun Heo wrote:
>
>  void __thaw_task(struct task_struct *p)
>  {
>  	unsigned long flags;
> @@ -150,11 +135,19 @@ void __thaw_task(struct task_struct *p)
>  	 * be visible to @p as waking up implies wmb.  Waking up inside
>  	 * freezer_lock also prevents wakeups from leaking outside
>  	 * refrigerator.
> +	 *
> +	 * If !FROZEN, @p hasn't reached refrigerator, recalc sigpending to
> +	 * avoid leaving dangling TIF_SIGPENDING behind.
>  	 */
>  	spin_lock_irqsave(&freezer_lock, flags);
>  	clear_freeze_flag(p);
> -	if (frozen(p))
> +	if (frozen(p)) {
>  		wake_up_process(p);
> +	} else {
> +		spin_lock(&p->sighand->siglock);
> +		recalc_sigpending_and_wake(p);

This was copied from cancel_, yes. but what this
recalc_sigpending_and_wake() can or should do?

It looks simply pointless. It can't clear TIF_SIGPENDING,
it can only do the unneeded/spurious wake_up(INTERRUPTIBLE).

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

Powered by Openwall GNU/*/Linux Powered by OpenVZ