u-boot/drivers/phy/allwinner
Andre Przywara 3c0b9adb89 sunxi: usb: convert PHY GPIO functions to DM
The Allwinner USB PHY driver is still using the legacy GPIO interface,
which is now implemented by the DM_GPIO compat functions.
Those seem to have some design flaws, as setting the direction, then
later setting the value will not work, if the DM_GPIO driver is
implementing set_flags.

Fix this by using the dm_ version of the direct GPIO interface, which
uses struct gpio_desc structs to handle requested GPIOs, and actually
keeps the flags we set earlier.

This fixes USB operation on boards which need to toggle the VBUS supply
via a GPIO, like the Teres-I laptop or the BananaPi M2 Berry board.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reported-by: Milan P. Stanić <mps@arvanta.net>
Reviewed-by: Samuel Holland <samuel@sholland.org>
2022-06-26 11:22:53 +01:00
..
Kconfig phy: sun4i-usb: Support VBUS detection via power supply 2021-10-25 14:49:28 +01:00
Makefile phy: sun50i-usb3: Add a driver for the H6 USB3 PHY 2021-09-22 21:29:56 +02:00
phy-sun4i-usb.c sunxi: usb: convert PHY GPIO functions to DM 2022-06-26 11:22:53 +01:00
phy-sun50i-usb3.c phy: sun50i-usb3: Add a driver for the H6 USB3 PHY 2021-09-22 21:29:56 +02:00