From: "Luis R. Rodriguez" <mcgrof@gmail.com>
To: "Rafael J. Wysocki" <rjw@sisk.pl>, netdev@vger.kernel.org
Cc: ath5k-devel@venema.h4ckr.net,
"John W. Linville" <linville@tuxdriver.com>,
linux-wireless@vger.kernel.org, Bob Copeland <me@bobcopeland.com>,
LKML <linux-kernel@vger.kernel.org>,
pm list <linux-pm@lists.linux-foundation.org>
Subject: Re: [PATCH] Wireless / ath5k: Simplify suspend and resume callbacks
Date: Mon, 5 Oct 2009 16:21:02 +0000 [thread overview]
Message-ID: <43e72e890910050921q7f516c67ofe17603d6d873c4@mail.gmail.com> (raw)
In-Reply-To: <200910050052.09085.rjw@sisk.pl>
On Sun, Oct 4, 2009 at 10:52 PM, Rafael J. Wysocki <rjw@sisk.pl> wrote:
> From: Rafael J. Wysocki <rjw@sisk.pl>
>
> Simplify the suspend and resume callbacks of ath5k by converting the
> driver to struct dev_pm_ops and allowing the PCI PM core to do the
> PCI-specific suspend/resume handling.
>
> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Do you happen to know if the new dev_pm_ops thing handle WOL / WoW [1]?
[1] http://wireless.kernel.org/en/users/Documentation/WoW
> #ifdef CONFIG_PM
> -static int
> -ath5k_pci_suspend(struct pci_dev *pdev, pm_message_t state)
> +static int ath5k_pci_suspend(struct device *dev)
> {
> - struct ieee80211_hw *hw = pci_get_drvdata(pdev);
> + struct ieee80211_hw *hw = pci_get_drvdata(to_pci_dev(dev));
> struct ath5k_softc *sc = hw->priv;
>
> ath5k_led_off(sc);
> -
> - pci_save_state(pdev);
> - pci_disable_device(pdev);
For WoW right here we'd do
pci_prepare_to_sleep(pdev) and bail out.
> - pci_set_power_state(pdev, PCI_D3hot);
And here we'd call something like this:
pci_wake_from_d3(pdev, !!sc->wow_triggers_enabled);
> -
> return 0;
> }
Are all drivers being converted?
It'll be a while before we get WoW enabled on ath5k but it is
technically possible, the work was tested for ath9k back in July [2]
but I never submitted this to be merged due to some inconsistent
issues I was noticing with the hardware.
[2] http://kernel.org/pub/linux/kernel/people/mcgrof/patches/wow-07-21.patch
Luis
next prev parent reply other threads:[~2009-10-05 16:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-10-04 22:52 Rafael J. Wysocki
2009-10-05 16:21 ` Luis R. Rodriguez [this message]
2009-10-05 19:40 ` 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=43e72e890910050921q7f516c67ofe17603d6d873c4@mail.gmail.com \
--to=mcgrof@gmail.com \
--cc=ath5k-devel@venema.h4ckr.net \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@lists.linux-foundation.org \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=me@bobcopeland.com \
--cc=netdev@vger.kernel.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®