aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ieee1394/ohci1394.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ieee1394/ohci1394.c')
-rw-r--r--drivers/ieee1394/ohci1394.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/drivers/ieee1394/ohci1394.c b/drivers/ieee1394/ohci1394.c
index 8d92246bdc3b..54d686aed39f 100644
--- a/drivers/ieee1394/ohci1394.c
+++ b/drivers/ieee1394/ohci1394.c
@@ -3532,6 +3532,7 @@ static void ohci1394_pci_remove(struct pci_dev *pdev)
3532#ifdef CONFIG_PM 3532#ifdef CONFIG_PM
3533static int ohci1394_pci_resume (struct pci_dev *pdev) 3533static int ohci1394_pci_resume (struct pci_dev *pdev)
3534{ 3534{
3535/* PowerMac resume code comes first */
3535#ifdef CONFIG_PPC_PMAC 3536#ifdef CONFIG_PPC_PMAC
3536 if (machine_is(powermac)) { 3537 if (machine_is(powermac)) {
3537 struct device_node *of_node; 3538 struct device_node *of_node;
@@ -3543,17 +3544,19 @@ static int ohci1394_pci_resume (struct pci_dev *pdev)
3543 } 3544 }
3544#endif /* CONFIG_PPC_PMAC */ 3545#endif /* CONFIG_PPC_PMAC */
3545 3546
3547 pci_set_power_state(pdev, PCI_D0);
3546 pci_restore_state(pdev); 3548 pci_restore_state(pdev);
3547 pci_enable_device(pdev); 3549 pci_enable_device(pdev);
3548 3550
3549 return 0; 3551 return 0;
3550} 3552}
3551 3553
3552
3553static int ohci1394_pci_suspend (struct pci_dev *pdev, pm_message_t state) 3554static int ohci1394_pci_suspend (struct pci_dev *pdev, pm_message_t state)
3554{ 3555{
3555 pci_save_state(pdev); 3556 pci_save_state(pdev);
3557 pci_set_power_state(pdev, pci_choose_state(pdev, state));
3556 3558
3559/* PowerMac suspend code comes last */
3557#ifdef CONFIG_PPC_PMAC 3560#ifdef CONFIG_PPC_PMAC
3558 if (machine_is(powermac)) { 3561 if (machine_is(powermac)) {
3559 struct device_node *of_node; 3562 struct device_node *of_node;
@@ -3563,11 +3566,10 @@ static int ohci1394_pci_suspend (struct pci_dev *pdev, pm_message_t state)
3563 if (of_node) 3566 if (of_node)
3564 pmac_call_feature(PMAC_FTR_1394_ENABLE, of_node, 0, 0); 3567 pmac_call_feature(PMAC_FTR_1394_ENABLE, of_node, 0, 0);
3565 } 3568 }
3566#endif 3569#endif /* CONFIG_PPC_PMAC */
3567
3568 return 0; 3570 return 0;
3569} 3571}
3570#endif 3572#endif /* CONFIG_PM */
3571 3573
3572#define PCI_CLASS_FIREWIRE_OHCI ((PCI_CLASS_SERIAL_FIREWIRE << 8) | 0x10) 3574#define PCI_CLASS_FIREWIRE_OHCI ((PCI_CLASS_SERIAL_FIREWIRE << 8) | 0x10)
3573 3575