ARM: dts: stm32: enable USB OTG HS on stm32h743i-eval
authorAmelie Delaunay <amelie.delaunay@st.com>
Mon, 19 Feb 2018 08:46:00 +0000 (09:46 +0100)
committerAlexandre Torgue <alexandre.torgue@st.com>
Tue, 27 Feb 2018 14:37:46 +0000 (15:37 +0100)
This patch enables USB HS on stm32h743i-eval in OTG (DRD) mode.
The USB connector used will determine the role of USB OTG controller.

Signed-off-by: Amelie Delaunay <amelie.delaunay@st.com>
Signed-off-by: Alexandre Torgue <alexandre.torgue@st.com>
arch/arm/boot/dts/stm32h743-pinctrl.dtsi
arch/arm/boot/dts/stm32h743i-eval.dts

index ee5202d..0f15dfb 100644 (file)
                                        bias-disable;
                                };
                        };
+
+                       usbotg_hs_pins_a: usbotg-hs@0 {
+                               pins {
+                                       pinmux = <STM32_PINMUX('H', 4, AF10)>,  /* ULPI_NXT */
+                                                        <STM32_PINMUX('I', 11, AF10)>, /* ULPI_DIR> */
+                                                        <STM32_PINMUX('C', 0, AF10)>,  /* ULPI_STP> */
+                                                        <STM32_PINMUX('A', 5, AF10)>,  /* ULPI_CK> */
+                                                        <STM32_PINMUX('A', 3, AF10)>,  /* ULPI_D0> */
+                                                        <STM32_PINMUX('B', 0, AF10)>,  /* ULPI_D1> */
+                                                        <STM32_PINMUX('B', 1, AF10)>,  /* ULPI_D2> */
+                                                        <STM32_PINMUX('B', 10, AF10)>, /* ULPI_D3> */
+                                                        <STM32_PINMUX('B', 11, AF10)>, /* ULPI_D4> */
+                                                        <STM32_PINMUX('B', 12, AF10)>, /* ULPI_D5> */
+                                                        <STM32_PINMUX('B', 13, AF10)>, /* ULPI_D6> */
+                                                        <STM32_PINMUX('B', 5, AF10)>;  /* ULPI_D7> */
+                                       bias-disable;
+                                       drive-push-pull;
+                                       slew-rate = <2>;
+                               };
+                       };
                };
        };
 };
index 9f0e72c..1c615f6 100644 (file)
                regulator-max-microvolt = <3300000>;
                regulator-always-on;
        };
+
+       usbotg_hs_phy: usb-phy {
+               #phy-cells = <0>;
+               compatible = "usb-nop-xceiv";
+               clocks = <&rcc USB1ULPI_CK>;
+               clock-names = "main_clk";
+       };
+
 };
 
 &adc_12 {
        status = "okay";
 };
 
+&usbotg_hs {
+       pinctrl-0 = <&usbotg_hs_pins_a>;
+       pinctrl-names = "default";
+       phys = <&usbotg_hs_phy>;
+       phy-names = "usb2-phy";
+       dr_mode = "otg";
+       status = "okay";
+};