From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: David Brownell <david-b@pacbell.net>, linux-pm@lists.osdl.org
Subject: Re: RFC -- updated Documentation/power/devices.txt
Date: Mon, 24 Jul 2006 00:45:13 +0200 [thread overview]
Message-ID: <200607240045.13724.rjw@sisk.pl> (raw)
In-Reply-To: <Pine.LNX.4.44L0.0607230843160.31932-100000@netrider.rowland.org>
On Sunday 23 July 2006 15:03, Alan Stern wrote:
> On Sun, 23 Jul 2006, Rafael J. Wysocki wrote:
>
> > On Sunday 23 July 2006 05:59, Alan Stern wrote:
> > > On Sat, 22 Jul 2006, David Brownell wrote:
> > ]--snip--[
> > > Some simple questions may help start the ball rolling. During a system
> > > resume, should all devices be powered on full,
> >
> > IMHO that would be wasteful.
> >
> > > or should they be restored to the state they were in before the suspend?
> > > Or should there be a third possibility -- maybe some devices always on,
> > > others the way they were?
> >
> > I think the devices that were on before the suspend should stay on, because
> > that's what the user will expect to happen. For the same reason the devices
> > that had been switched off explicitly ("by the user") before the suspend
> > should stay off. For the others, the rule of thumb may be "off".
>
> To put it another way: Devices that were ON get restored to ON, and
> devices that were OFF (either because the user turned them off explicitly
> or because the driver decided to do its own runtime power management)
> get restored to OFF. In other words, devices get restored to the state
> they were in before suspend.
Yes.
> I don't see anything wrong with that. It does raise some more questions.
>
> Who should be responsible for remembering the device's state
> from before the system suspend: the PM core or the driver?
> (Note that the driver has a better idea of what that state
> actually was.)
It seems to be easier to leave it to the driver. However, I think the core
needs to have at least some control over it. Otherwise, for example,
the detection of misbehaving drivers would be quite difficult, IMHO.
> Upon resuming from a system suspend, is it better to tell the
> driver to "go directly to the saved state" or to turn the
> device back fully ON and then change to the saved state (if it
> wasn't fully ON before the system suspend)?
I think the rule should be "go directly to the saved state", if possible.
As far as the STR is concerned, the devices that were OFF before the
suspend are likely to be OFF after the resume, so it doesn't seem to be
reasonable to turn them ON just to switch them back OFF again.
Greetings,
Rafael
next prev parent reply other threads:[~2006-07-23 22:45 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-10 22:25 RFC -- updated Documentation/power/devices.txt David Brownell
2006-07-11 5:56 ` Andrew Morton
2006-07-11 16:38 ` David Brownell
2006-07-11 21:57 ` David Brownell
2006-07-12 12:25 ` Pavel Machek
2006-07-12 14:04 ` Alan Stern
2006-07-12 15:45 ` David Brownell
2006-07-12 16:03 ` Alan Stern
2006-07-23 1:37 ` David Brownell
2006-07-23 3:59 ` Alan Stern
2006-07-23 10:50 ` Rafael J. Wysocki
2006-07-23 13:03 ` Alan Stern
2006-07-23 22:45 ` Rafael J. Wysocki [this message]
2006-07-24 3:22 ` David Brownell
2006-07-24 9:46 ` Rafael J. Wysocki
2006-07-24 14:51 ` Alan Stern
2006-07-24 15:15 ` David Brownell
2006-07-24 15:42 ` Alan Stern
2006-07-24 17:11 ` David Brownell
2006-07-24 20:44 ` Alan Stern
2006-07-24 21:19 ` David Brownell
2006-07-25 15:42 ` Alan Stern
2006-08-10 23:38 ` [patch 2.6.18-rc] " David Brownell
2006-07-23 16:22 ` RFC -- " David Brownell
2006-07-11 14:40 ` Pavel Machek
2006-07-11 21:28 ` Pavel Machek
-- strict thread matches above, loose matches on Subject: below --
2006-07-11 7:56 Woodruff, Richard
2006-07-11 16:51 ` David Brownell
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=200607240045.13724.rjw@sisk.pl \
--to=rjw@sisk.pl \
--cc=david-b@pacbell.net \
--cc=linux-pm@lists.osdl.org \
--cc=stern@rowland.harvard.edu \
/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