diff options
Diffstat (limited to 'drivers/usb/core/hcd-pci.c')
| -rw-r--r-- | drivers/usb/core/hcd-pci.c | 13 | 
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/usb/core/hcd-pci.c b/drivers/usb/core/hcd-pci.c index 9b77f49b3560..ab2f3737764e 100644 --- a/drivers/usb/core/hcd-pci.c +++ b/drivers/usb/core/hcd-pci.c @@ -558,6 +558,17 @@ static int hcd_pci_suspend_noirq(struct device *dev)  	return retval;  } +static int hcd_pci_poweroff_late(struct device *dev) +{ +	struct pci_dev		*pci_dev = to_pci_dev(dev); +	struct usb_hcd		*hcd = pci_get_drvdata(pci_dev); + +	if (hcd->driver->pci_poweroff_late && !HCD_DEAD(hcd)) +		return hcd->driver->pci_poweroff_late(hcd, device_may_wakeup(dev)); + +	return 0; +} +  static int hcd_pci_resume_noirq(struct device *dev)  {  	powermac_set_asic(to_pci_dev(dev), 1); @@ -578,6 +589,7 @@ static int hcd_pci_restore(struct device *dev)  #define hcd_pci_suspend		NULL  #define hcd_pci_suspend_noirq	NULL +#define hcd_pci_poweroff_late	NULL  #define hcd_pci_resume_noirq	NULL  #define hcd_pci_resume		NULL  #define hcd_pci_restore		NULL @@ -615,6 +627,7 @@ const struct dev_pm_ops usb_hcd_pci_pm_ops = {  	.thaw_noirq	= NULL,  	.thaw		= hcd_pci_resume,  	.poweroff	= hcd_pci_suspend, +	.poweroff_late	= hcd_pci_poweroff_late,  	.poweroff_noirq	= hcd_pci_suspend_noirq,  	.restore_noirq	= hcd_pci_resume_noirq,  	.restore	= hcd_pci_restore,  |