All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nigel Cunningham <nigel@nigel.suspend2.net>
To: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Matthew Garrett <mjg59@srcf.ucam.org>,
	Miklos Szeredi <miklos@szeredi.hu>,
	nigel@suspend2.net, LKML <linux-kernel@vger.kernel.org>,
	Pavel Machek <pavel@ucw.cz>,
	pm list <linux-pm@lists.linux-foundation.org>,
	Ingo Molnar <mingo@elte.hu>
Subject: Re: [RFC][PATCH -mm] PM: Do not sync filesystems from within the freezer
Date: Fri, 6 Jul 2007 17:07:20 +1000	[thread overview]
Message-ID: <200707061707.23316.nigel@nigel.suspend2.net> (raw)
In-Reply-To: <200707060902.55090.rjw@sisk.pl>


[-- Attachment #1.1: Type: text/plain, Size: 1524 bytes --]

Hi.

On Friday 06 July 2007 17:02:53 Rafael J. Wysocki wrote:
> On Friday, 6 July 2007 00:00, Pavel Machek wrote:
> > Hi!
> > 
> > > From: Rafael J. Wysocki <rjw@sisk.pl>
> > > 
> > > The syncing of filesystems from within the freezer is generally not 
needed.
> > > Change freeze_processes() so that it doesn't execute sys_sync() and make 
the
> > > suspend and hibernation code path sync filesystems independently of the 
freezer.
> > 
> > Yes, we can do that, but ... why?
> 
> I think that sync and the freezer are different things and shouldn't be 
mixed in
> such a way as they are now.
> 
> > Does it actually fix FUSE?
> 
> It should prevent the freezer from deadlocking.

That's not the same thing. It's like saying "My footbrake grabs so I'll use 
the handbrake all the time. Take the stone out of the brake pad! :)

> > Miklos claims sync is nop on FUSE...? 
> 
> In that case there shouldn't be any deadlock, but a freezer failure. :-)

Isn't this scary? I'm agreeing with Pavel and the two of us seem to be 
disagreeing with everyone else!

To get more serious and practical though, I think the solution is to fuzz the 
userspace/kernelspace distinction. What we really want to do is freeze things 
that submit I/O, then sync, then freeze anything that processes I/O and needs 
to be frozen. In effect, redefine fuse processes as freezeable kernel 
threads.

Regards,

Nigel
-- 
See http://www.tuxonice.net for Howtos, FAQs, mailing
lists, wiki and bugzilla info.

[-- Attachment #1.2: Type: application/pgp-signature, Size: 189 bytes --]

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



WARNING: multiple messages have this Message-ID (diff)
From: Nigel Cunningham <nigel@nigel.suspend2.net>
To: "Rafael J. Wysocki" <rjw@sisk.pl>
Cc: Pavel Machek <pavel@ucw.cz>,
	pm list <linux-pm@lists.linux-foundation.org>,
	nigel@suspend2.net,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	LKML <linux-kernel@vger.kernel.org>,
	Matthew Garrett <mjg59@srcf.ucam.org>,
	Oliver Neukum <oliver@neukum.org>,
	Paul Mackerras <paulus@samba.org>,
	Miklos Szeredi <miklos@szeredi.hu>, Ingo Molnar <mingo@elte.hu>
Subject: Re: [RFC][PATCH -mm] PM: Do not sync filesystems from within the freezer
Date: Fri, 6 Jul 2007 17:07:20 +1000	[thread overview]
Message-ID: <200707061707.23316.nigel@nigel.suspend2.net> (raw)
In-Reply-To: <200707060902.55090.rjw@sisk.pl>

[-- Attachment #1: Type: text/plain, Size: 1524 bytes --]

Hi.

On Friday 06 July 2007 17:02:53 Rafael J. Wysocki wrote:
> On Friday, 6 July 2007 00:00, Pavel Machek wrote:
> > Hi!
> > 
> > > From: Rafael J. Wysocki <rjw@sisk.pl>
> > > 
> > > The syncing of filesystems from within the freezer is generally not 
needed.
> > > Change freeze_processes() so that it doesn't execute sys_sync() and make 
the
> > > suspend and hibernation code path sync filesystems independently of the 
freezer.
> > 
> > Yes, we can do that, but ... why?
> 
> I think that sync and the freezer are different things and shouldn't be 
mixed in
> such a way as they are now.
> 
> > Does it actually fix FUSE?
> 
> It should prevent the freezer from deadlocking.

That's not the same thing. It's like saying "My footbrake grabs so I'll use 
the handbrake all the time. Take the stone out of the brake pad! :)

> > Miklos claims sync is nop on FUSE...? 
> 
> In that case there shouldn't be any deadlock, but a freezer failure. :-)

Isn't this scary? I'm agreeing with Pavel and the two of us seem to be 
disagreeing with everyone else!

To get more serious and practical though, I think the solution is to fuzz the 
userspace/kernelspace distinction. What we really want to do is freeze things 
that submit I/O, then sync, then freeze anything that processes I/O and needs 
to be frozen. In effect, redefine fuse processes as freezeable kernel 
threads.

Regards,

Nigel
-- 
See http://www.tuxonice.net for Howtos, FAQs, mailing
lists, wiki and bugzilla info.

[-- Attachment #2: Type: application/pgp-signature, Size: 189 bytes --]

  reply	other threads:[~2007-07-06  7:07 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-04 14:58 [RFC][PATCH -mm] PM: Do not sync from within the freezer during suspend to RAM Rafael J. Wysocki
2007-07-04 22:48 ` Nigel Cunningham
2007-07-04 22:49   ` Pavel Machek
2007-07-04 22:49   ` Pavel Machek
2007-07-04 22:52     ` Nigel Cunningham
2007-07-05 11:28       ` Rafael J. Wysocki
2007-07-05 11:28         ` Rafael J. Wysocki
2007-07-05 11:37         ` Nigel Cunningham
2007-07-05 20:31           ` [RFC][PATCH -mm] PM: Do not sync filesystems from within the freezer Rafael J. Wysocki
2007-07-05 22:00             ` Pavel Machek
2007-07-06  7:02               ` Rafael J. Wysocki
2007-07-06  7:07                 ` Nigel Cunningham [this message]
2007-07-06  7:07                   ` Nigel Cunningham
2007-07-06  7:13                   ` Miklos Szeredi
2007-07-06  7:13                     ` Miklos Szeredi
2007-07-06  7:19                     ` Nigel Cunningham
2007-07-06  7:36                       ` Miklos Szeredi
2007-07-06  7:36                       ` Miklos Szeredi
2007-07-07 11:48                         ` possible solution for problem 2 (was Re: [RFC][PATCH -mm] PM: Do not sync filesystems from within the freezer) Pavel Machek
2007-07-07 11:48                           ` Pavel Machek
2007-07-06  7:19                     ` [RFC][PATCH -mm] PM: Do not sync filesystems from within the freezer Nigel Cunningham
2007-07-06  8:59                     ` Benjamin Herrenschmidt
2007-07-06  8:59                       ` Benjamin Herrenschmidt
2007-07-06  9:05                       ` Miklos Szeredi
2007-07-06  9:13                         ` Nigel Cunningham
2007-07-06  9:13                           ` Nigel Cunningham
2007-07-06  9:31                           ` Miklos Szeredi
2007-07-06  9:31                             ` Miklos Szeredi
2007-07-06 10:00                             ` Rafael J. Wysocki
2007-07-06 10:00                             ` Rafael J. Wysocki
2007-07-06  9:05                       ` Miklos Szeredi
2007-07-06  7:02               ` Rafael J. Wysocki
2007-07-05 22:00             ` Pavel Machek
2007-07-05 11:37         ` [RFC][PATCH -mm] PM: Do not sync from within the freezer during suspend to RAM Nigel Cunningham
2007-07-04 22:52     ` Nigel Cunningham
2007-07-04 22:48 ` Nigel Cunningham

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=200707061707.23316.nigel@nigel.suspend2.net \
    --to=nigel@nigel.suspend2.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=miklos@szeredi.hu \
    --cc=mingo@elte.hu \
    --cc=mjg59@srcf.ucam.org \
    --cc=nigel@suspend2.net \
    --cc=pavel@ucw.cz \
    --cc=rjw@sisk.pl \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.