Skip to content
Commit c3d6450e authored by Jarkko Nikula's avatar Jarkko Nikula Committed by Greg Kroah-Hartman
Browse files

usb: otg: twl4030-usb: Fix unbalanced regulator disables at module removal



Function twl4030_usb_remove can cause unbalanced regulator disables in
twl4030_phy_power if the cable is not connected. Regulator enable/disable
calls are in balance only if the twl4030_phy_resume was called prior the
twl4030_usb_remove, that is, the cable was connected.

Fix this by checking the 'asleep' variable in twl4030_usb_remove since that
variable is used to check state in other functions.

Signed-off-by: default avatarJarkko Nikula <jhnikula@gmail.com>
Cc: Felipe Balbi <balbi@ti.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 02303f73
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment