skge: adapt skge to use reworked PCI PM
authorRafael J. Wysocki <rjw@sisk.pl>
Wed, 29 Oct 2008 21:22:14 +0000 (14:22 -0700)
committerJeff Garzik <jgarzik@redhat.com>
Fri, 31 Oct 2008 04:52:17 +0000 (00:52 -0400)
commit5177b3240a6608fc0c9c05cc32f4855c6540f8d5
treea3a8063d2b722e5df04853f82483ee23759e85c7
parentc8db3fec5b02f4cefe441903fe1c142ff14e1771
skge: adapt skge to use reworked PCI PM

Adapt the skge driver to the reworked PCI PM

* Use device_set_wakeup_enable() and friends as needed
* Remove an open-coded reference to the standard PCI PM registers
* Use pci_prepare_to_sleep() and pci_back_from_sleep() in the
  ->suspend() and ->resume() callbacks
* Use the observation that it is sufficient to call pci_enable_wake()
  once, unless it fails

Tested on Asus L5D (Yukon-Lite rev 7).

Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Cc: Stephen Hemminger <shemminger@linux-foundation.org>
Cc: Jeff Garzik <jeff@garzik.org>
Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
drivers/net/skge.c