summaryrefslogtreecommitdiff
path: root/drivers/usb
diff options
context:
space:
mode:
authorTony Lindgren <tony@atomide.com>2019-03-22 14:54:05 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-05-31 06:46:30 -0700
commit239156e0c04ae1fded24dee0236d966f44fed645 (patch)
treefb7666f82b2181e2c42fef8284650550f0422867 /drivers/usb
parent506b28fb998280c6b704945893520c97f7311a1c (diff)
downloadlinux-rpi3-239156e0c04ae1fded24dee0236d966f44fed645.tar.gz
linux-rpi3-239156e0c04ae1fded24dee0236d966f44fed645.tar.bz2
linux-rpi3-239156e0c04ae1fded24dee0236d966f44fed645.zip
usb: core: Add PM runtime calls to usb_hcd_platform_shutdown
[ Upstream commit 8ead7e817224d7832fe51a19783cb8fcadc79467 ] If ohci-platform is runtime suspended, we can currently get an "imprecise external abort" on reboot with ohci-platform loaded when PM runtime is implemented for the SoC. Let's fix this by adding PM runtime support to usb_hcd_platform_shutdown. Signed-off-by: Tony Lindgren <tony@atomide.com> Acked-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'drivers/usb')
-rw-r--r--drivers/usb/core/hcd.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c
index 1c21955fe7c0..b82a7d787add 100644
--- a/drivers/usb/core/hcd.c
+++ b/drivers/usb/core/hcd.c
@@ -3017,6 +3017,9 @@ usb_hcd_platform_shutdown(struct platform_device *dev)
{
struct usb_hcd *hcd = platform_get_drvdata(dev);
+ /* No need for pm_runtime_put(), we're shutting down */
+ pm_runtime_get_sync(&dev->dev);
+
if (hcd->driver->shutdown)
hcd->driver->shutdown(hcd);
}