aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide')
-rw-r--r--drivers/ide/ppc/pmac.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/drivers/ide/ppc/pmac.c b/drivers/ide/ppc/pmac.c
index 996c694341b..31ad79f52df 100644
--- a/drivers/ide/ppc/pmac.c
+++ b/drivers/ide/ppc/pmac.c
@@ -1369,15 +1369,16 @@ pmac_ide_macio_attach(struct macio_dev *mdev, const struct of_device_id *match)
1369} 1369}
1370 1370
1371static int 1371static int
1372pmac_ide_macio_suspend(struct macio_dev *mdev, pm_message_t state) 1372pmac_ide_macio_suspend(struct macio_dev *mdev, pm_message_t mesg)
1373{ 1373{
1374 ide_hwif_t *hwif = (ide_hwif_t *)dev_get_drvdata(&mdev->ofdev.dev); 1374 ide_hwif_t *hwif = (ide_hwif_t *)dev_get_drvdata(&mdev->ofdev.dev);
1375 int rc = 0; 1375 int rc = 0;
1376 1376
1377 if (state.event != mdev->ofdev.dev.power.power_state.event && state.event >= PM_EVENT_SUSPEND) { 1377 if (mesg.event != mdev->ofdev.dev.power.power_state.event
1378 && mesg.event == PM_EVENT_SUSPEND) {
1378 rc = pmac_ide_do_suspend(hwif); 1379 rc = pmac_ide_do_suspend(hwif);
1379 if (rc == 0) 1380 if (rc == 0)
1380 mdev->ofdev.dev.power.power_state = state; 1381 mdev->ofdev.dev.power.power_state = mesg;
1381 } 1382 }
1382 1383
1383 return rc; 1384 return rc;
@@ -1473,15 +1474,16 @@ pmac_ide_pci_attach(struct pci_dev *pdev, const struct pci_device_id *id)
1473} 1474}
1474 1475
1475static int 1476static int
1476pmac_ide_pci_suspend(struct pci_dev *pdev, pm_message_t state) 1477pmac_ide_pci_suspend(struct pci_dev *pdev, pm_message_t mesg)
1477{ 1478{
1478 ide_hwif_t *hwif = (ide_hwif_t *)pci_get_drvdata(pdev); 1479 ide_hwif_t *hwif = (ide_hwif_t *)pci_get_drvdata(pdev);
1479 int rc = 0; 1480 int rc = 0;
1480 1481
1481 if (state.event != pdev->dev.power.power_state.event && state.event >= 2) { 1482 if (mesg.event != pdev->dev.power.power_state.event
1483 && mesg.event == PM_EVENT_SUSPEND) {
1482 rc = pmac_ide_do_suspend(hwif); 1484 rc = pmac_ide_do_suspend(hwif);
1483 if (rc == 0) 1485 if (rc == 0)
1484 pdev->dev.power.power_state = state; 1486 pdev->dev.power.power_state = mesg;
1485 } 1487 }
1486 1488
1487 return rc; 1489 return rc;