diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-10-10 16:39:32 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2008-10-10 16:39:32 -0400 |
commit | feb22b7f8e62b1b987a3a1dbad95af767a1df832 (patch) | |
tree | 428e5294a077fc629caa3706396e835b164eee7c /drivers/ide/pci/via82cxxx.c | |
parent | 1785192b5310ee25165768f5bb80f13146788e3e (diff) |
ide: add proper PCI PM support (v2)
* Keep pointer to ->init_chipset method also in
struct ide_host and set it in ide_host_alloc_all().
* Add ide_pci_suspend() and ide_pci_resume() helpers
(default ->suspend and ->resume implementations).
* ->init_chipset can no longer be marked __devinit.
* Add proper PCI PM support to IDE PCI host drivers
(rz1000.c and tc86c001.c are skipped for now since
they need to be converted from using ->init_hwif
to use ->init_chipset instead).
v2:
* Cleanup CONFIG_PM #ifdef-s per akpm's suggestion.
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/pci/via82cxxx.c')
-rw-r--r-- | drivers/ide/pci/via82cxxx.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/ide/pci/via82cxxx.c b/drivers/ide/pci/via82cxxx.c index 9cb531dc905a..acacdaab69c2 100644 --- a/drivers/ide/pci/via82cxxx.c +++ b/drivers/ide/pci/via82cxxx.c | |||
@@ -215,7 +215,7 @@ static struct via_isa_bridge *via_config_find(struct pci_dev **isa) | |||
215 | /* | 215 | /* |
216 | * Check and handle 80-wire cable presence | 216 | * Check and handle 80-wire cable presence |
217 | */ | 217 | */ |
218 | static void __devinit via_cable_detect(struct via82cxxx_dev *vdev, u32 u) | 218 | static void via_cable_detect(struct via82cxxx_dev *vdev, u32 u) |
219 | { | 219 | { |
220 | int i; | 220 | int i; |
221 | 221 | ||
@@ -267,7 +267,7 @@ static void __devinit via_cable_detect(struct via82cxxx_dev *vdev, u32 u) | |||
267 | * and initialize its drive independent registers. | 267 | * and initialize its drive independent registers. |
268 | */ | 268 | */ |
269 | 269 | ||
270 | static unsigned int __devinit init_chipset_via82cxxx(struct pci_dev *dev) | 270 | static unsigned int init_chipset_via82cxxx(struct pci_dev *dev) |
271 | { | 271 | { |
272 | struct ide_host *host = pci_get_drvdata(dev); | 272 | struct ide_host *host = pci_get_drvdata(dev); |
273 | struct via82cxxx_dev *vdev = host->host_priv; | 273 | struct via82cxxx_dev *vdev = host->host_priv; |
@@ -492,6 +492,8 @@ static struct pci_driver driver = { | |||
492 | .id_table = via_pci_tbl, | 492 | .id_table = via_pci_tbl, |
493 | .probe = via_init_one, | 493 | .probe = via_init_one, |
494 | .remove = __devexit_p(via_remove), | 494 | .remove = __devexit_p(via_remove), |
495 | .suspend = ide_pci_suspend, | ||
496 | .resume = ide_pci_resume, | ||
495 | }; | 497 | }; |
496 | 498 | ||
497 | static int __init via_ide_init(void) | 499 | static int __init via_ide_init(void) |