phy: phy-twl4030-usb: Disable PHY for suspend
authorTony Lindgren <tony@atomide.com>
Tue, 27 Jul 2021 10:45:12 +0000 (13:45 +0300)
committerVinod Koul <vkoul@kernel.org>
Fri, 6 Aug 2021 12:02:51 +0000 (17:32 +0530)
commit7481f91f1d7e8a004f19b55747d38a934119abe2
tree5430a17bfd9a85934cf6ea28c1ce42ef14a82427
parenta69f29cb50a0069f3442c08fcf21fad55d48f4d2
phy: phy-twl4030-usb: Disable PHY for suspend

Since commit 88d26136a256 ("PM: Prevent runtime suspend during system
resume"), PM runtime will not let devices idle during system suspend.

This is because of the pm_runtime_get_noresume() call done in
device_prepare() that is not released until at device_complete() after
resume.

We must now disable the USB PHY in suspend if no USB cable is connected.

Cc: Andreas Kemnade <andreas@kemnade.info>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Link: https://lore.kernel.org/r/20210727104512.52968-1-tony@atomide.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/ti/phy-twl4030-usb.c