aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/ata/ata_piix.c6
-rw-r--r--drivers/pci/pci-driver.c2
-rw-r--r--drivers/pci/pci.c7
-rw-r--r--include/linux/pci.h2
4 files changed, 8 insertions, 9 deletions
diff --git a/drivers/ata/ata_piix.c b/drivers/ata/ata_piix.c
index ad070861bb53..6089fbc5b89f 100644
--- a/drivers/ata/ata_piix.c
+++ b/drivers/ata/ata_piix.c
@@ -973,10 +973,10 @@ static int piix_pci_device_resume(struct pci_dev *pdev)
973 pci_restore_state(pdev); 973 pci_restore_state(pdev);
974 974
975 /* PCI device wasn't disabled during suspend. Use 975 /* PCI device wasn't disabled during suspend. Use
976 * __pci_reenable_device() to avoid affecting the 976 * pci_reenable_device() to avoid affecting the enable
977 * enable count. 977 * count.
978 */ 978 */
979 rc = __pci_reenable_device(pdev); 979 rc = pci_reenable_device(pdev);
980 if (rc) 980 if (rc)
981 dev_printk(KERN_ERR, &pdev->dev, "failed to enable " 981 dev_printk(KERN_ERR, &pdev->dev, "failed to enable "
982 "device after resume (%d)\n", rc); 982 "device after resume (%d)\n", rc);
diff --git a/drivers/pci/pci-driver.c b/drivers/pci/pci-driver.c
index 8e58ea3d95c0..004bc2487270 100644
--- a/drivers/pci/pci-driver.c
+++ b/drivers/pci/pci-driver.c
@@ -310,7 +310,7 @@ static int pci_default_resume(struct pci_dev *pci_dev)
310 /* restore the PCI config space */ 310 /* restore the PCI config space */
311 pci_restore_state(pci_dev); 311 pci_restore_state(pci_dev);
312 /* if the device was enabled before suspend, reenable */ 312 /* if the device was enabled before suspend, reenable */
313 retval = __pci_reenable_device(pci_dev); 313 retval = pci_reenable_device(pci_dev);
314 /* if the device was busmaster before the suspend, make it busmaster again */ 314 /* if the device was busmaster before the suspend, make it busmaster again */
315 if (pci_dev->is_busmaster) 315 if (pci_dev->is_busmaster)
316 pci_set_master(pci_dev); 316 pci_set_master(pci_dev);
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
index 1ee9cd9c86e2..37c00f6fd801 100644
--- a/drivers/pci/pci.c
+++ b/drivers/pci/pci.c
@@ -695,14 +695,13 @@ static int do_pci_enable_device(struct pci_dev *dev, int bars)
695} 695}
696 696
697/** 697/**
698 * __pci_reenable_device - Resume abandoned device 698 * pci_reenable_device - Resume abandoned device
699 * @dev: PCI device to be resumed 699 * @dev: PCI device to be resumed
700 * 700 *
701 * Note this function is a backend of pci_default_resume and is not supposed 701 * Note this function is a backend of pci_default_resume and is not supposed
702 * to be called by normal code, write proper resume handler and use it instead. 702 * to be called by normal code, write proper resume handler and use it instead.
703 */ 703 */
704int 704int pci_reenable_device(struct pci_dev *dev)
705__pci_reenable_device(struct pci_dev *dev)
706{ 705{
707 if (atomic_read(&dev->enable_cnt)) 706 if (atomic_read(&dev->enable_cnt))
708 return do_pci_enable_device(dev, (1 << PCI_NUM_RESOURCES) - 1); 707 return do_pci_enable_device(dev, (1 << PCI_NUM_RESOURCES) - 1);
@@ -1604,7 +1603,7 @@ early_param("pci", pci_setup);
1604device_initcall(pci_init); 1603device_initcall(pci_init);
1605 1604
1606EXPORT_SYMBOL_GPL(pci_restore_bars); 1605EXPORT_SYMBOL_GPL(pci_restore_bars);
1607EXPORT_SYMBOL(__pci_reenable_device); 1606EXPORT_SYMBOL(pci_reenable_device);
1608EXPORT_SYMBOL(pci_enable_device_bars); 1607EXPORT_SYMBOL(pci_enable_device_bars);
1609EXPORT_SYMBOL(pci_enable_device); 1608EXPORT_SYMBOL(pci_enable_device);
1610EXPORT_SYMBOL(pcim_enable_device); 1609EXPORT_SYMBOL(pcim_enable_device);
diff --git a/include/linux/pci.h b/include/linux/pci.h
index d8f8a3a96644..e7d8d4e19a53 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -534,7 +534,7 @@ static inline int pci_write_config_dword(struct pci_dev *dev, int where, u32 val
534 534
535int __must_check pci_enable_device(struct pci_dev *dev); 535int __must_check pci_enable_device(struct pci_dev *dev);
536int __must_check pci_enable_device_bars(struct pci_dev *dev, int mask); 536int __must_check pci_enable_device_bars(struct pci_dev *dev, int mask);
537int __must_check __pci_reenable_device(struct pci_dev *); 537int __must_check pci_reenable_device(struct pci_dev *);
538int __must_check pcim_enable_device(struct pci_dev *pdev); 538int __must_check pcim_enable_device(struct pci_dev *pdev);
539void pcim_pin_device(struct pci_dev *pdev); 539void pcim_pin_device(struct pci_dev *pdev);
540 540