public inbox for linux-acpi@vger.kernel.org
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rjw@sisk.pl>
To: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: Alan Stern <stern@rowland.harvard.edu>,
	Pavel Machek <pavel@suse.cz>,
	ACPI Devel Maling List <linux-acpi@vger.kernel.org>,
	pm list <linux-pm@lists.linux-foundation.org>
Subject: Re: [linux-pm] [PATCH 2/2] PCI PM: Introduce pci_preferred_state
Date: Sat, 10 May 2008 00:57:01 +0200	[thread overview]
Message-ID: <200805100057.01656.rjw@sisk.pl> (raw)
In-Reply-To: <200805091513.04194.jbarnes@virtuousgeek.org>

On Saturday, 10 of May 2008, Jesse Barnes wrote:
> On Friday, May 09, 2008 2:44 pm Rafael J. Wysocki wrote:
> > Okay, what about this:
> >
> > ---
> > From: Rafael J. Wysocki <rjw@sisk.pl>
> >
> > The new suspend and hibernation callbacks introduced with
> > 'struct pm_ops' and 'struct pm_ext_ops' do not take a
> > pm_message_t argument, so the drivers using them will not be able
> > to use pci_choose_state() in its present form.  For this reason,
> > introduce a new function, pci_choose_and_set_state(), playing the
> > role of pci_choose_state() combined with pci_set_power_state() and
> > allowing the driver to put the device into a power state chosen by
> > the platform.
> 
> Yeah, that looks pretty good.  The name is long but I can't think of a better 
> one offhand.  Can you also update Documentation/power/pci.txt with the latest 
> best practices?

I'm going to do that, eventually, but rather in a separate patch, when
everything is ready for the new framework, while at the moment we still have
some design work to do.

For example, some drivers may want to call pci_enable_wake() for the
target state and that must be done before pci_set_power_state() in case the
target state is D3cold.  To allow them to do that, we'll need a variant of
pci_choose_and_set_state() with a 'wake_enabled' argument.

> I wonder if we should do a pass through the drivers converting them to this
> interface as well... 

Well, that would be lots of work and since we'd like the drivers to switch to
the new framework entirely, we'll need to pass through them anyway for this
purpose.  I'd prefer that to be one pass. ;-)

Thanks,
Rafael

  reply	other threads:[~2008-05-09 22:56 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-05-06 21:42 [PATCH 0/2] Patches for 2.6.27, dependent on the other trees Rafael J. Wysocki
2008-05-06 21:44 ` [PATCH 1/2] ACPI PM: Add suspend sequence workaround Rafael J. Wysocki
2008-05-06 21:57   ` Carlos Corbacho
2008-05-06 22:09     ` Rafael J. Wysocki
2008-05-07  9:29   ` Pavel Machek
2008-05-07 12:21     ` Rafael J. Wysocki
2008-05-09 17:20       ` Rafael J. Wysocki
2008-05-09 17:21         ` [RFC][PATCH 1/2] ACPI PM: Remove obsolete Toshiba workaround Rafael J. Wysocki
2008-05-12  7:18           ` Pavel Machek
2008-05-09 17:23         ` [RFC][PATCH 2/2] ACPI PM: Add possibility to change suspend sequence Rafael J. Wysocki
2008-05-12  7:23           ` Pavel Machek
2008-05-12 22:34             ` Rafael J. Wysocki
2008-05-12 23:03               ` Rafael J. Wysocki
2008-05-19 22:36                 ` Pavel Machek
2008-05-06 21:49 ` [PATCH 2/2] PCI PM: Introduce pci_preferred_state Rafael J. Wysocki
2008-05-07  9:33   ` Pavel Machek
2008-05-07 12:22     ` Rafael J. Wysocki
2008-05-07 15:45       ` [linux-pm] " Alan Stern
2008-05-07 18:32         ` Rafael J. Wysocki
2008-05-09 15:44           ` Rafael J. Wysocki
2008-05-09 16:47             ` Jesse Barnes
2008-05-09 17:13               ` [linux-pm] " Rafael J. Wysocki
2008-05-09 17:24                 ` Jesse Barnes
2008-05-09 17:34                   ` [linux-pm] " Rafael J. Wysocki
2008-05-09 17:37                     ` Jesse Barnes
2008-05-09 21:44                       ` Rafael J. Wysocki
2008-05-09 22:13                         ` Jesse Barnes
2008-05-09 22:57                           ` Rafael J. Wysocki [this message]
2008-05-10 18:28                             ` Rafael J. Wysocki
2008-05-12 14:00                         ` Pavel Machek
2008-05-12 14:52                           ` Rafael J. Wysocki

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=200805100057.01656.rjw@sisk.pl \
    --to=rjw@sisk.pl \
    --cc=jbarnes@virtuousgeek.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=pavel@suse.cz \
    --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