usb: phy: tegra: Keep track of power on-off state
authorDmitry Osipenko <digetx@gmail.com>
Mon, 6 Jan 2020 01:34:00 +0000 (04:34 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 9 Jan 2020 10:15:31 +0000 (11:15 +0100)
commit18bd8bff69f7fbc53903dba4a1c234a30a8fcbde
tree4f468d57864e14faf800f427b14b8ff9ab1397f0
parent28d190ac437c675763f03b17407ea16c1dd8c613
usb: phy: tegra: Keep track of power on-off state

The PHY driver should keep track of the enable state, otherwise enable
refcount is screwed if USB driver tries to enable PHY when it is already
enabled. This will be the case for ChipIdea and Tegra EHCI drivers once
PHY driver will gain support for the init/shutdown callbacks.

Signed-off-by: Dmitry Osipenko <digetx@gmail.com>
Link: https://lore.kernel.org/r/20200106013416.9604-5-digetx@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/phy/phy-tegra-usb.c
include/linux/usb/tegra_usb_phy.h