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] [day] [month] [year] [list]
Date:	Tue, 4 Dec 2007 01:05:32 +0100
From:	"Rafael J. Wysocki" <rjw@...k.pl>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	"Pete MacKay" <armlinux@...hitechnical.net>,
	LKML <linux-kernel@...r.kernel.org>,
	David Woodhouse <dwmw2@...radead.org>
Subject: Re: [PATCH] Freezer: Fix JFFS2 garbage collector freezing issue (was: Re: JFFS2 garbage collection threads not freezing?)

On Saturday, 1 of December 2007, Rafael J. Wysocki wrote:
> On Friday, 30 of November 2007, Pete MacKay wrote:
[--snip--]
> ---
> Subject: Freezer: Fix JFFS2 garbage collector freezing issue
> From: Rafael J. Wysocki <rjw@...k.pl>
> 
> Fix breakage caused by commit d5d8c5976d6adeddb8208c240460411e2198b393
> "freezer: do not send signals to kernel threads" in
> jffs2_garbage_collect_thread() that assumed it would be sent signals
> by the freezer.
> 
> Signed-off-by: Rafael J. Wysocki <rjw@...k.pl>
> Cc: Pete MacKay <armlinux@...hitechnical.net>
> Cc: Andrew Morton <akpm@...ux-foundation.org>
> ---
>  fs/jffs2/background.c |    8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
> 
> Index: linux-2.6/fs/jffs2/background.c
> ===================================================================
> --- linux-2.6.orig/fs/jffs2/background.c
> +++ linux-2.6/fs/jffs2/background.c
> @@ -103,15 +103,17 @@ static int jffs2_garbage_collect_thread(
>  		   get there first. */
>  		yield();
>  
> +		/* If system suspend is in progress, go to the refrigerator and
> +		   start again when the suspend is done */
> +		if (try_to_freeze())
> +			goto again;
> +

This still has the problem that, if the freeze request comes exactly here, the
loop below will not allow us to freeze.

>  		/* Put_super will send a SIGKILL and then wait on the sem.
>  		 */
>  		while (signal_pending(current)) {
>  			siginfo_t info;
>  			unsigned long signr;
>  
> -			if (try_to_freeze())
> -				goto again;
> -
>  			signr = dequeue_signal_lock(current, &current->blocked, &info);
>  
>  			switch(signr) {
> --

I'll send another patch for this in a while.

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

Powered by Openwall GNU/*/Linux Powered by OpenVZ