ramips: use regulator for USB

The DWC2 driver used here supports a vbus-supply property to control
the GPIO. Use it instead of the local gpio,exports solution.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Link: https://github.com/openwrt/openwrt/pull/17357
Signed-off-by: Robert Marko <robimarko@gmail.com>
This commit is contained in:
Rosen Penev 2024-12-23 14:20:29 -08:00 committed by Robert Marko
parent 6a1bdcf545
commit 0cdcba238f

View File

@ -94,15 +94,12 @@
};
};
gpio_export {
compatible = "gpio-export";
#size-cells = <0>;
usb {
gpio-export,name = "usb";
gpio-export,output = <0>;
gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
reg_usb_power: regulator {
compatible = "regulator-fixed";
regulator-name = "usb_power";
regulator-min-microvolt = <5000000>;
regulator-max-microvolt = <5000000>;
gpios = <&gpio0 11 GPIO_ACTIVE_LOW>;
};
};
@ -129,4 +126,6 @@
&otg {
status = "okay";
vbus-supply = <&reg_usb_power>;
};