arm64: dts: ti: k3-am62a7-sk: Enable dual role support for Type-C port
authorRavi Gunasekaran <r-gunasekaran@ti.com>
Tue, 25 Jul 2023 10:36:51 +0000 (16:06 +0530)
committerNishanth Menon <nm@ti.com>
Sat, 5 Aug 2023 19:04:26 +0000 (14:04 -0500)
USB0 is interfaced with a Type-C DRP connector and is managed via a
USB PD controller. Add support for the Type-C port with dual data
and power sink role.

Signed-off-by: Ravi Gunasekaran <r-gunasekaran@ti.com>
Reviewed-by: Roger Quadros <rogerq@kernel.org>
Link: https://lore.kernel.org/r/20230725103651.1612-1-r-gunasekaran@ti.com
Signed-off-by: Nishanth Menon <nm@ti.com>
arch/arm64/boot/dts/ti/k3-am62a7-sk.dts

index d2cca618273825df56c77490a9df06b4e6b20369..cff283c75f8ecd78e03910a54f8df04908d0f912 100644 (file)
        pinctrl-names = "default";
        pinctrl-0 = <&main_i2c0_pins_default>;
        clock-frequency = <400000>;
+
+       typec_pd0: usb-power-controller@3f {
+               compatible = "ti,tps6598x";
+               reg = <0x3f>;
+
+               connector {
+                       compatible = "usb-c-connector";
+                       label = "USB-C";
+                       self-powered;
+                       data-role = "dual";
+                       power-role = "sink";
+                       port {
+                               usb_con_hs: endpoint {
+                                       remote-endpoint = <&usb0_hs_ep>;
+                               };
+                       };
+               };
+       };
 };
 
 &main_i2c1 {
        status = "reserved";
 };
 
+&usbss0 {
+       status = "okay";
+       ti,vbus-divider;
+};
+
+&usb0 {
+       usb-role-switch;
+
+       port {
+               usb0_hs_ep: endpoint {
+                       remote-endpoint = <&usb_con_hs>;
+               };
+       };
+};
+
 &usbss1 {
        status = "okay";
 };