diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2005-07-28 14:37:33 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2005-09-08 17:57:25 -0400 |
commit | 95a629657dbe28e44a312c47815b3dc3f1ce0970 (patch) | |
tree | 0e48656b5d61e26078a50af9f6766e52934fbedf /drivers/pci/pcie | |
parent | 085ae41f66657a9655ce832b0a61832a06f0e1dc (diff) |
[PATCH] PCI: start paying attention to a lot of pci function return values
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
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 | /* |