]> git.baikalelectronics.ru Git - uboot.git/commit
phy: sun4i-usb: Do not drive VBUS with external VBUS present
authorSamuel Holland <samuel@sholland.org>
Fri, 15 Jul 2022 03:34:53 +0000 (22:34 -0500)
committerAndre Przywara <andre.przywara@arm.com>
Fri, 28 Apr 2023 00:30:40 +0000 (01:30 +0100)
commit259050054fb4ced91dd392a8437de47cc41bb28b
tree910e69df6f0774bfc5cd53bd29b84024ee1c54ee
parent6fd4dd3918a1c68551d3de093f1e5f88452e93e3
phy: sun4i-usb: Do not drive VBUS with external VBUS present

It is possible to use host-side USB with externally-provided VBUS. For
example, some USB OTG cables have an extra power input which powers
both the board and the USB peripheral.

To support this setup, skip enabling the VBUS switch/regulator if VBUS
voltage is already present. This behavior matches the Linux PHY driver.

Signed-off-by: Samuel Holland <samuel@sholland.org>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
drivers/phy/allwinner/phy-sun4i-usb.c