diff options
author | Peter Chen <peter.chen@freescale.com> | 2014-07-03 10:17:35 +0800 |
---|---|---|
committer | Peter Chen <peter.chen@freescale.com> | 2014-07-04 17:31:07 +0800 |
commit | a09ff37e60e0cbd67347d067837a9358ef25ecc8 (patch) | |
tree | 06426dc05a5be1ee388bd75b90e2588458b4cbd0 /drivers | |
parent | dbf45927ac7e149c28a3aac4bfa7768acbbb8e35 (diff) |
ENGR00311619 usb: chipidea: core: run resume if controller is at low power mode
Controller needs to be active during system suspend, otherwise the core
may run resume when the parent is still at suspend if other driver's
suspend fails, it occurs before parent's suspend has not started,
but the core suspend has finished.
Signed-off-by: Peter Chen <peter.chen@freescale.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/usb/chipidea/core.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c index b6c57161985c..be6afb3042ff 100644 --- a/drivers/usb/chipidea/core.c +++ b/drivers/usb/chipidea/core.c @@ -933,6 +933,15 @@ static int ci_suspend(struct device *dev) struct ci_hdrc *ci = dev_get_drvdata(dev); int ret; + /* + * Controller needs to be active during suspend, otherwise the core + * may run resume when the parent is at suspend if other driver's + * suspend fails, it occurs before parent's suspend has not started, + * but the core suspend has finished. + */ + if (ci->in_lpm) + pm_runtime_resume(dev); + ret = ci_controller_suspend(dev); if (ret) return ret; |