aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMathias Kresin <dev@kresin.me>2021-02-17 23:37:54 +0100
committerMathias Kresin <dev@kresin.me>2021-02-18 00:21:30 +0100
commit6aef4bc7c396d19690ef989143d0bbcbb0fbdde1 (patch)
tree7e9ef29e15ee78c2370bc0f37e0aafb0043d1f67
parent6bf5bfc19f8442bdce42eae0769e7095a1ea8add (diff)
downloadupstream-6aef4bc7c396d19690ef989143d0bbcbb0fbdde1.tar.gz
upstream-6aef4bc7c396d19690ef989143d0bbcbb0fbdde1.tar.bz2
upstream-6aef4bc7c396d19690ef989143d0bbcbb0fbdde1.zip
lantiq: fritz7320: enable USB power supply
The USB ports if a FRIZZ!Box 7320 do not supply power to connected devices. Add the GPIOs enabling USB power as regulator, to enable USB power supply as soon as the USB driver is loaded. Fixes FS#3624 Signed-off-by: Mathias Kresin <dev@kresin.me> (cherry picked from commit 6e4e97b2256327bb380ee2a83da9a1ddf657e395)
-rw-r--r--target/linux/lantiq/files-4.14/arch/mips/boot/dts/FRITZ7320.dts46
1 files changed, 46 insertions, 0 deletions
diff --git a/target/linux/lantiq/files-4.14/arch/mips/boot/dts/FRITZ7320.dts b/target/linux/lantiq/files-4.14/arch/mips/boot/dts/FRITZ7320.dts
index 89fc3858b7..262bd8d25f 100644
--- a/target/linux/lantiq/files-4.14/arch/mips/boot/dts/FRITZ7320.dts
+++ b/target/linux/lantiq/files-4.14/arch/mips/boot/dts/FRITZ7320.dts
@@ -72,6 +72,30 @@
gpios = <&gpio 45 GPIO_ACTIVE_LOW>;
};
};
+
+ usb0_vbus: regulator-usb0-vbus {
+ compatible = "regulator-fixed";
+
+ regulator-name = "USB0_VBUS";
+
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+
+ gpio = <&gpio 50 GPIO_ACTIVE_HIGH>;
+ enable-active-high;
+ };
+
+ usb1_vbus: regulator-usb1-vbus {
+ compatible = "regulator-fixed";
+
+ regulator-name = "USB1_VBUS";
+
+ regulator-min-microvolt = <5000000>;
+ regulator-max-microvolt = <5000000>;
+
+ gpio = <&gpio 51 GPIO_ACTIVE_HIGH>;
+ enable-active-high;
+ };
};
&gpio {
@@ -103,6 +127,26 @@
mtd-mac-address-increment = <(-2)>;
};
+&gpio {
+ pinctrl-names = "default";
+ pinctrl-0 = <&state_default>;
+
+ state_default: pinmux {
+ usb0_vbus {
+ lantiq,pins = "io50";
+ lantiq,pull = <0>;
+ lantiq,open-drain = <0>;
+ lantiq,output = <1>;
+ };
+ usb1_vbus {
+ lantiq,pins = "io51";
+ lantiq,pull = <0>;
+ lantiq,open-drain = <0>;
+ lantiq,output = <1>;
+ };
+ };
+};
+
&localbus {
nor@0 {
compatible = "lantiq,nor";
@@ -164,8 +208,10 @@
&usb0 {
status = "okay";
+ vbus-supply = <&usb0_vbus>;
};
&usb1 {
status = "okay";
+ vbus-supply = <&usb1_vbus>;
};