diff options
Diffstat (limited to 'drivers/pci/pcie')
-rw-r--r-- | drivers/pci/pcie/portdrv_pci.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/pci/pcie/portdrv_pci.c b/drivers/pci/pcie/portdrv_pci.c index 30bac7ed7c16..3c565ce7f77b 100644 --- a/drivers/pci/pcie/portdrv_pci.c +++ b/drivers/pci/pcie/portdrv_pci.c | |||
@@ -90,15 +90,19 @@ static void pcie_portdrv_save_config(struct pci_dev *dev) | |||
90 | pci_save_msi_state(dev); | 90 | pci_save_msi_state(dev); |
91 | } | 91 | } |
92 | 92 | ||
93 | static void pcie_portdrv_restore_config(struct pci_dev *dev) | 93 | static int pcie_portdrv_restore_config(struct pci_dev *dev) |
94 | { | 94 | { |
95 | struct pcie_port_device_ext *p_ext = pci_get_drvdata(dev); | 95 | struct pcie_port_device_ext *p_ext = pci_get_drvdata(dev); |
96 | int retval; | ||
96 | 97 | ||
97 | pci_restore_state(dev); | 98 | pci_restore_state(dev); |
98 | if (p_ext->interrupt_mode == PCIE_PORT_MSI_MODE) | 99 | if (p_ext->interrupt_mode == PCIE_PORT_MSI_MODE) |
99 | pci_restore_msi_state(dev); | 100 | pci_restore_msi_state(dev); |
100 | pci_enable_device(dev); | 101 | retval = pci_enable_device(dev); |
102 | if (retval) | ||
103 | return retval; | ||
101 | pci_set_master(dev); | 104 | pci_set_master(dev); |
105 | return 0; | ||
102 | } | 106 | } |
103 | 107 | ||
104 | /* | 108 | /* |