[PATCH] PCI: start paying attention to a lot of pci function return values
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
@@ -272,17 +272,19 @@ static int pci_device_suspend(struct device * dev, pm_message_t state)
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
/*
|
||||
* Default resume method for devices that have no driver provided resume,
|
||||
* or not even a driver at all.
|
||||
*/
|
||||
static void pci_default_resume(struct pci_dev *pci_dev)
|
||||
{
|
||||
int retval;
|
||||
|
||||
/* restore the PCI config space */
|
||||
pci_restore_state(pci_dev);
|
||||
/* if the device was enabled before suspend, reenable */
|
||||
if (pci_dev->is_enabled)
|
||||
pci_enable_device(pci_dev);
|
||||
retval = pci_enable_device(pci_dev);
|
||||
/* if the device was busmaster before the suspend, make it busmaster again */
|
||||
if (pci_dev->is_busmaster)
|
||||
pci_set_master(pci_dev);
|
||||
|
Reference in New Issue
Block a user