Skip to content

Commit f6c274e

Browse files
author
Felipe Balbi
committed
usb: dwc3: pci: runtime_resume child device
During runtime_resume of dwc3-pci.c, we need to runtime suspend our child device (which is dwc3 proper) otherwise nothing will happen. Signed-off-by: Felipe Balbi <[email protected]>
1 parent fa8410b commit f6c274e

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

drivers/usb/dwc3/dwc3-pci.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,13 @@ static int dwc3_pci_runtime_suspend(struct device *dev)
243243
return -EBUSY;
244244
}
245245

246+
static int dwc3_pci_runtime_resume(struct device *dev)
247+
{
248+
struct platform_device *dwc3 = dev_get_drvdata(dev);
249+
250+
return pm_runtime_get(&dwc3->dev);
251+
}
252+
246253
static int dwc3_pci_pm_dummy(struct device *dev)
247254
{
248255
/*
@@ -259,7 +266,7 @@ static int dwc3_pci_pm_dummy(struct device *dev)
259266

260267
static struct dev_pm_ops dwc3_pci_dev_pm_ops = {
261268
SET_SYSTEM_SLEEP_PM_OPS(dwc3_pci_pm_dummy, dwc3_pci_pm_dummy)
262-
SET_RUNTIME_PM_OPS(dwc3_pci_runtime_suspend, dwc3_pci_pm_dummy,
269+
SET_RUNTIME_PM_OPS(dwc3_pci_runtime_suspend, dwc3_pci_runtime_resume,
263270
NULL)
264271
};
265272

0 commit comments

Comments
 (0)