From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Pavel Machek <pavel@ucw.cz>
Cc: linux-pm@lists.linux-foundation.org,
Nigel Cunningham <ncunningham@crca.org.au>,
"Leisner, Martin" <Martin.Leisner@xerox.com>
Subject: Re: syncing the disks when entering sleep
Date: Wed, 10 Feb 2010 20:19:26 +0100 [thread overview]
Message-ID: <201002102019.26518.rjw@sisk.pl> (raw)
In-Reply-To: <20100210133118.GA31861@atrey.karlin.mff.cuni.cz>
On Wednesday 10 February 2010, Pavel Machek wrote:
> > On Wednesday 10 February 2010, Pavel Machek wrote:
> > > > Hi.
> > > >
> > > > Pavel Machek wrote:
> > > > >> So you're asking to give this knob "one shot behavior" (i.e. "then
> > > > >> next sleep won't sync")?
> > > > >
> > > > > Yes.
> > > > >
> > > > >> But I'm primarily interested in the behavior on embedded systems
> > > > >> (where you control all the processes running -- there's no "user"
> > > > >> involved.
> > > > >>
> > > > >
> > > > > Well, then "one shot behaviour" does not hurt you, right?
> > > > >
> > > > >> If a user starts messing with default settings, any unwanted
> > > > >> behavior is the users problem (besides, this should only be
> > > > >> writable as root).
> > > > >>
> > > > >
> > > > > I'd rather not add traps for the user unless absolutely neccessary.
> > > > > Not even for root user. Pavel
> > > >
> > > > But that's precisely what you're doing. You're advocating making the
> > > > behaviour inconsistent. If what you're suggesting is done, you won't be
> > > > able to simply cat the sysfs entry to know whether sys_syncing is going
> > > > to be done on the next cycle. You'll also have to have knowledge of
> > > > whether a cycle has been done since the last time the value is set. The
> > > > end result will be someone getting trapped and caught out because they
> > > > think '1' in /sys/power/dont_sync (or whatever it's called) means what
> > > > it says.
> > >
> > > I'm simply advocating that setting from one suspend should not change
> > > other suspends ... because you have multiple different programs
> > > wanting to suspend the system, all independend.
> >
> > Which is wrong. There should be one power manager everybody else calls to
> > suspend the system. Yes, even if the battery is running critical.
>
> Really? If so then it is misdesigned.
>
> Before the "don't sync" proposal, it was okay to have multiple
> power managers.
>
> Actually I have three on zaurus. There's in-kernel suspend on battery
> critical, then there's somehing userspace in desktop environment, and
> then I'm triggering suspends by hand using echo.
To be precise, 1 and 3 are things that override the power manager.
And if you override the power manager, you're supposed to know what you're
doing, aren't you?
> > So really, I don't see anything wrong with a knob that will turn the kernel
> > sync off entirely, because that basically means "my user space is
> > not broken".
>
> Because, very easily, parts of my users space may be broken.
How exactly would they be broken?
Why do you want to protect the users from themselves for what it's worth?
Why don't we just assume that the user who sets the knob knows what he's doing?
Rafael
next prev parent reply other threads:[~2010-02-10 19:19 UTC|newest]
Thread overview: 48+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-22 15:59 syncing the disks when entering sleep Leisner, Martin
2010-01-22 20:49 ` Rafael J. Wysocki
2010-01-22 21:31 ` Nigel Cunningham
2010-01-22 21:33 ` Leisner, Martin
2010-01-22 21:38 ` Rafael J. Wysocki
2010-01-22 21:40 ` Leisner, Martin
2010-01-22 21:55 ` Nigel Cunningham
2010-01-22 22:06 ` Nigel Cunningham
2010-01-22 21:35 ` Rafael J. Wysocki
2010-01-26 13:59 ` Pavel Machek
2010-01-26 18:17 ` Rafael J. Wysocki
2010-01-26 14:51 ` Pavel Machek
2010-01-27 0:51 ` Rafael J. Wysocki
2010-01-27 6:45 ` Pavel Machek
2010-01-27 7:29 ` Nigel Cunningham
2010-01-27 20:50 ` Rafael J. Wysocki
2010-01-28 7:26 ` Pavel Machek
2010-01-28 10:43 ` Rafael J. Wysocki
2010-04-05 6:38 ` document open(/dev/snapshot) sideeffects -- was " Pavel Machek
[not found] ` <20100405063852.GA1924@elf.ucw.cz>
2010-04-23 18:28 ` Rafael J. Wysocki
[not found] ` <201004232028.56005.rjw@sisk.pl>
2010-04-24 5:42 ` Pavel Machek
2010-01-27 9:55 ` Pavel Machek
2010-01-27 20:46 ` Rafael J. Wysocki
2010-01-31 8:52 ` Pavel Machek
2010-01-31 12:33 ` Rafael J. Wysocki
2010-02-01 10:49 ` Pavel Machek
2010-02-01 17:13 ` Leisner, Martin
2010-02-01 21:09 ` Pavel Machek
2010-02-02 4:13 ` Nigel Cunningham
2010-02-10 8:13 ` Pavel Machek
2010-02-10 10:34 ` Rafael J. Wysocki
2010-02-10 10:38 ` Oliver Neukum
2010-02-10 10:58 ` Rafael J. Wysocki
2010-02-10 11:02 ` Oliver Neukum
2010-02-10 18:42 ` Rafael J. Wysocki
2010-02-15 20:28 ` Matthew Garrett
2010-02-16 6:38 ` Pavel Machek
2010-02-10 13:31 ` Pavel Machek
2010-02-10 19:19 ` Rafael J. Wysocki [this message]
2010-02-10 21:17 ` Leisner, Martin
2010-02-11 14:49 ` Pavel Machek
2010-02-11 15:00 ` Pavel Machek
2010-02-11 17:28 ` Rafael J. Wysocki
2010-02-11 20:17 ` Nigel Cunningham
2010-02-10 20:58 ` Leisner, Martin
2010-02-01 20:55 ` Nigel Cunningham
2010-02-01 21:07 ` Pavel Machek
2010-02-01 22:03 ` 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=201002102019.26518.rjw@sisk.pl \
--to=rjw@sisk.pl \
--cc=Martin.Leisner@xerox.com \
--cc=linux-pm@lists.linux-foundation.org \
--cc=ncunningham@crca.org.au \
--cc=pavel@ucw.cz \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox