ARM: dts: imx6: pfla02: Fix USB vbus enable pinmuxing
Subsystems (2)
PATCH 1/3 ARM: dts: imx6: pfla02: Fix USB vbus enable pinmuxing
The pinmuxing for the enable pin of the usbh1 node is wrong. It needs to be muxed as GPIO. While at it, move the pinctrl to the vbus regulator since it is actually the regulator enable pin.
--- arch/arm/boot/dts/imx6qdl-phytec-pfla02.dtsi | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
arch/arm/boot/dts/imx6qdl-phytec-pfla02.dtsi +4 -4
@@ -31,6 +31,8 @@ reg_usb_otg_vbus: regulator@0 { reg_usb_h1_vbus: regulator@1 { compatible = "regulator-fixed"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_usbh1_vbus>; reg = <1>; regulator-name = "usb_h1_vbus"; regulator-min-microvolt = <5000000>;
@@ -328,9 +330,9 @@ MX6QDL_PAD_KEY_ROW0__UART4_RX_DATA 0x1b0b1 >; }; - pinctrl_usbh1: usbh1grp { + pinctrl_usbh1_vbus: usbh1vbusgrp { fsl,pins = < - MX6QDL_PAD_GPIO_0__USB_H1_PWR 0x80000000 + MX6QDL_PAD_GPIO_0__GPIO1_IO00 0x80000000 >; };
@@ -415,8 +417,6 @@ &uart4 { &usbh1 { vbus-supply = <®_usb_h1_vbus>; - pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_usbh1>; status = "disabled"; };
Signature · 1 line
2.25.1
PATCH 2/3 ARM: dts: imx6: pbab01: Set USB OTG port to peripheral
Due to a hardware bug preventing the correct detection if the ID pin the USB OTG port cannot be used in otg mode. It can either be set to host or peripheral. Set it to peripheral so vbus is disabled by default.
--- arch/arm/boot/dts/imx6qdl-phytec-pbab01.dtsi | 1 + 1 file changed, 1 insertion(+)
arch/arm/boot/dts/imx6qdl-phytec-pbab01.dtsi +1 -0
@@ -164,6 +164,7 @@ &usbh1 { &usbotg { status = "okay"; + dr_mode = "peripheral"; }; &usdhc2 {
Signature · 1 line
2.25.1
Re: [PATCH 2/3] ARM: dts: imx6: pbab01: Set USB OTG port to peripheral
Quoted 6 lines · Stefan Riedmueller
Due to a hardware bug preventing the correct detection if the ID pin the USB OTG port cannot be used in otg mode. It can either be set to host or peripheral. Set it to peripheral so vbus is disabled by default.
Signed-off-by Stefan Riedmueller <[email protected]>
PATCH 3/3 ARM: dts: imx6: pbab01: Set vmmc supply for both SD interfaces
In reply to Stefan RiedmuellerSetting the vmmc supplies is crucial since otherwise the supplying regulators get disabled and the SD interfaces are no longer powered which leads to system failures if the system is booted from that SD interface.
--- arch/arm/boot/dts/imx6qdl-phytec-pfla02.dtsi | 2 ++ 1 file changed, 2 insertions(+)
arch/arm/boot/dts/imx6qdl-phytec-pfla02.dtsi +2 -0
@@ -433,6 +433,7 @@ &usdhc2 { pinctrl-0 = <&pinctrl_usdhc2>; cd-gpios = <&gpio1 4 GPIO_ACTIVE_LOW>; wp-gpios = <&gpio1 2 GPIO_ACTIVE_HIGH>; + vmmc-supply = <&vdd_sd1_reg>; status = "disabled"; };
@@ -442,5 +443,6 @@ &usdhc3 { &pinctrl_usdhc3_cdwp>; cd-gpios = <&gpio1 27 GPIO_ACTIVE_LOW>; wp-gpios = <&gpio1 29 GPIO_ACTIVE_HIGH>; + vmmc-supply = <&vdd_sd0_reg>; status = "disabled"; };
Signature · 1 line
2.25.1
Re: [PATCH 3/3] ARM: dts: imx6: pbab01: Set vmmc supply for both SD interfaces
Quoted 5 lines · Stefan Riedmueller
Setting the vmmc supplies is crucial since otherwise the supplying regulators get disabled and the SD interfaces are no longer powered which leads to system failures if the system is booted from that SD interface.
It seems that this deserves a Fixes tag.
Re: [PATCH 3/3] ARM: dts: imx6: pbab01: Set vmmc supply for both SD interfaces
Hi Fabio,
Quoted 8 lines · Fabio Estevam
Quoted 4 lines · Stefan Riedmueller
Setting the vmmc supplies is crucial since otherwise the supplying regulators get disabled and the SD interfaces are no longer powered which leads to system failures if the system is booted from that SD interface.
It seems that this deserves a Fixes tag.
I think this must be broken for some time now. My guess is that it broke when the PMIC support for the SOM was added. So I can add a fixes tag for that commit.
Thanks,
Stefan
Quoted 2 lines
Reviewed-by Fabio Estevam <[email protected]>
Fabio Estevam
reviewerHi Stefan,
arch/arm/boot/dts/imx6qdl-phytec-pfla02.dtsi MX6QDL_PAD_KEY_ROW0__UART4_RX_DATA 0x1b0b1 · line 335
Quoted 5 lines · Stefan Riedmueller
arch/arm/boot/dts/imx6qdl-phytec-pfla02.dtsi +2
-2- pinctrl_usbh1: usbh1grp { + pinctrl_usbh1_vbus: usbh1vbusgrp { fsl,pins = < - MX6QDL_PAD_GPIO_0__USB_H1_PWR 0x80000000 + MX6QDL_PAD_GPIO_0__GPIO1_IO00 0x80000000
While you are on it, could you please use avoid the usage of 0x80000000 and explicitly pass the default value instead?
Hi Fabio,
Quoted 13 lines · Fabio Estevam
Hi Stefan,
Quoted 7 lines · Stefan Riedmueller
arch/arm/boot/dts/imx6qdl-phytec-pfla02.dtsi +1
-2- pinctrl_usbh1: usbh1grp { + pinctrl_usbh1_vbus: usbh1vbusgrp { fsl,pins = < - MX6QDL_PAD_GPIO_0__USB_H1_PWR 0x80000000
+MX6QDL_PAD_GPIO_0__GPIO1_IO000x
80000000
Quoted 2 lines
While you are on it, could you please use avoid the usage of
0x80000000and explicitly pass the default value instead?
Thanks for your review. Sure, I'll fix that in a v2.
Stefan