.. | .. |
---|
8 | 8 | #include <dt-bindings/display/drm_mipi_dsi.h> |
---|
9 | 9 | #include <dt-bindings/sensor-dev.h> |
---|
10 | 10 | #include <dt-bindings/pwm/pwm.h> |
---|
| 11 | +#include "dt-bindings/usb/pd.h" |
---|
11 | 12 | #include "rk3399pro.dtsi" |
---|
12 | 13 | #include "rk3399-linux.dtsi" |
---|
13 | 14 | #include "rk3399-opp.dtsi" |
---|
.. | .. |
---|
201 | 202 | status = "disabled"; |
---|
202 | 203 | }; |
---|
203 | 204 | |
---|
| 205 | + vbus_typec: vbus-typec-regulator { |
---|
| 206 | + compatible = "regulator-fixed"; |
---|
| 207 | + enable-active-high; |
---|
| 208 | + gpio = <&gpio1 18 GPIO_ACTIVE_HIGH>; |
---|
| 209 | + pinctrl-names = "default"; |
---|
| 210 | + pinctrl-0 = <&vcc5v0_typec0_en>; |
---|
| 211 | + regulator-name = "vbus_typec"; |
---|
| 212 | + vin-supply = <&vcc5v0_sys>; |
---|
| 213 | + }; |
---|
| 214 | + |
---|
| 215 | + vbus_typec: vbus-typec-regulator { |
---|
| 216 | + compatible = "regulator-fixed"; |
---|
| 217 | + enable-active-high; |
---|
| 218 | + gpio = <&gpio1 18 GPIO_ACTIVE_HIGH>; |
---|
| 219 | + pinctrl-names = "default"; |
---|
| 220 | + pinctrl-0 = <&vcc5v0_typec0_en>; |
---|
| 221 | + regulator-name = "vbus_typec"; |
---|
| 222 | + vin-supply = <&vcc5v0_sys>; |
---|
| 223 | + }; |
---|
| 224 | + |
---|
204 | 225 | vcc_phy: vcc-phy-regulator { |
---|
205 | 226 | compatible = "regulator-fixed"; |
---|
206 | 227 | regulator-name = "vcc_phy"; |
---|
.. | .. |
---|
243 | 264 | |
---|
244 | 265 | &cdn_dp { |
---|
245 | 266 | status = "okay"; |
---|
246 | | - extcon = <&fusb0>; |
---|
247 | 267 | phys = <&tcphy0_dp>; |
---|
248 | 268 | }; |
---|
249 | 269 | |
---|
.. | .. |
---|
614 | 634 | }; |
---|
615 | 635 | }; |
---|
616 | 636 | |
---|
617 | | - vdd_cpu_b: tcs452x@1c { |
---|
618 | | - compatible = "tcs,tcs452x"; |
---|
| 637 | + vdd_cpu_b: tcs4525@1c { |
---|
| 638 | + compatible = "tcs,tcs4525"; |
---|
619 | 639 | reg = <0x1c>; |
---|
620 | 640 | vin-supply = <&vcc5v0_sys>; |
---|
621 | 641 | regulator-compatible = "fan53555-reg"; |
---|
.. | .. |
---|
634 | 654 | }; |
---|
635 | 655 | }; |
---|
636 | 656 | |
---|
637 | | - vdd_gpu: tcs452x@10 { |
---|
638 | | - compatible = "tcs,tcs452x"; |
---|
| 657 | + vdd_gpu: tcs4526@10 { |
---|
| 658 | + compatible = "tcs,tcs4526"; |
---|
639 | 659 | reg = <0x10>; |
---|
640 | 660 | vin-supply = <&vcc5v0_sys>; |
---|
641 | 661 | regulator-compatible = "fan53555-reg"; |
---|
.. | .. |
---|
657 | 677 | bq25700: bq25700@6b { |
---|
658 | 678 | compatible = "ti,bq25703"; |
---|
659 | 679 | reg = <0x6b>; |
---|
660 | | - extcon = <&fusb0>; |
---|
661 | 680 | interrupt-parent = <&gpio1>; |
---|
662 | 681 | interrupts = <RK_PA1 IRQ_TYPE_LEVEL_LOW>; |
---|
663 | 682 | pinctrl-names = "default"; |
---|
.. | .. |
---|
786 | 805 | i2c-scl-falling-time-ns = <11>; |
---|
787 | 806 | clock-frequency = <100000>; |
---|
788 | 807 | |
---|
789 | | - fusb0: fusb30x@22 { |
---|
790 | | - compatible = "fairchild,fusb302"; |
---|
| 808 | + usbc0: fusb302@22 { |
---|
| 809 | + compatible = "fcs,fusb302"; |
---|
791 | 810 | reg = <0x22>; |
---|
| 811 | + interrupt-parent = <&gpio1>; |
---|
| 812 | + interrupts = <RK_PA2 IRQ_TYPE_LEVEL_LOW>; |
---|
792 | 813 | pinctrl-names = "default"; |
---|
793 | | - pinctrl-0 = <&fusb0_int>; |
---|
794 | | - int-n-gpios = <&gpio1 RK_PA2 GPIO_ACTIVE_HIGH>; |
---|
795 | | - vbus-5v-gpios = <&gpio0 RK_PA1 GPIO_ACTIVE_LOW>; |
---|
| 814 | + pinctrl-0 = <&usbc0_int>; |
---|
| 815 | + vbus-supply = <&vbus_typec>; |
---|
796 | 816 | status = "okay"; |
---|
797 | | - }; |
---|
798 | 817 | |
---|
| 818 | + ports { |
---|
| 819 | + #address-cells = <1>; |
---|
| 820 | + #size-cells = <0>; |
---|
| 821 | + |
---|
| 822 | + port@0 { |
---|
| 823 | + reg = <0>; |
---|
| 824 | + usbc0_role_sw: endpoint@0 { |
---|
| 825 | + remote-endpoint = <&dwc3_0_role_switch>; |
---|
| 826 | + }; |
---|
| 827 | + }; |
---|
| 828 | + }; |
---|
| 829 | + |
---|
| 830 | + usb_con: connector { |
---|
| 831 | + compatible = "usb-c-connector"; |
---|
| 832 | + label = "USB-C"; |
---|
| 833 | + data-role = "dual"; |
---|
| 834 | + power-role = "dual"; |
---|
| 835 | + try-power-role = "sink"; |
---|
| 836 | + op-sink-microwatt = <1000000>; |
---|
| 837 | + sink-pdos = |
---|
| 838 | + <PDO_FIXED(5000, 2500, PDO_FIXED_USB_COMM)>; |
---|
| 839 | + source-pdos = |
---|
| 840 | + <PDO_FIXED(5000, 1500, PDO_FIXED_USB_COMM)>; |
---|
| 841 | + |
---|
| 842 | + ports { |
---|
| 843 | + #address-cells = <1>; |
---|
| 844 | + #size-cells = <0>; |
---|
| 845 | + |
---|
| 846 | + port@0 { |
---|
| 847 | + reg = <0>; |
---|
| 848 | + usbc0_orien_sw: endpoint { |
---|
| 849 | + remote-endpoint = <&tcphy0_orientation_switch>; |
---|
| 850 | + }; |
---|
| 851 | + }; |
---|
| 852 | + }; |
---|
| 853 | + }; |
---|
| 854 | + }; |
---|
799 | 855 | }; |
---|
800 | 856 | |
---|
801 | 857 | &i2s1 { |
---|
.. | .. |
---|
995 | 1051 | }; |
---|
996 | 1052 | |
---|
997 | 1053 | &tcphy0 { |
---|
998 | | - extcon = <&fusb0>; |
---|
999 | 1054 | status = "okay"; |
---|
| 1055 | + orientation-switch; |
---|
| 1056 | + port { |
---|
| 1057 | + #address-cells = <1>; |
---|
| 1058 | + #size-cells = <0>; |
---|
| 1059 | + tcphy0_orientation_switch: endpoint@0 { |
---|
| 1060 | + reg = <0>; |
---|
| 1061 | + remote-endpoint = <&usbc0_orien_sw>; |
---|
| 1062 | + }; |
---|
| 1063 | + }; |
---|
1000 | 1064 | }; |
---|
1001 | 1065 | |
---|
1002 | 1066 | &tcphy1 { |
---|
.. | .. |
---|
1011 | 1075 | |
---|
1012 | 1076 | &u2phy0 { |
---|
1013 | 1077 | status = "okay"; |
---|
1014 | | - extcon = <&fusb0>; |
---|
1015 | 1078 | |
---|
1016 | 1079 | u2phy0_otg: otg-port { |
---|
1017 | 1080 | status = "okay"; |
---|
.. | .. |
---|
1067 | 1130 | |
---|
1068 | 1131 | &usbdrd_dwc3_0 { |
---|
1069 | 1132 | status = "okay"; |
---|
1070 | | - extcon = <&fusb0>; |
---|
| 1133 | + usb-role-switch; |
---|
| 1134 | + port { |
---|
| 1135 | + #address-cells = <1>; |
---|
| 1136 | + #size-cells = <0>; |
---|
| 1137 | + dwc3_0_role_switch: endpoint@0 { |
---|
| 1138 | + reg = <0>; |
---|
| 1139 | + remote-endpoint = <&usbc0_role_sw>; |
---|
| 1140 | + }; |
---|
| 1141 | + }; |
---|
1071 | 1142 | }; |
---|
1072 | 1143 | |
---|
1073 | 1144 | &usbdrd_dwc3_1 { |
---|
.. | .. |
---|
1105 | 1176 | cam_pwren_high: cam-pwren-high { |
---|
1106 | 1177 | rockchip,pins = |
---|
1107 | 1178 | <4 RK_PC5 RK_FUNC_GPIO &pcfg_output_high>; |
---|
1108 | | - }; |
---|
1109 | | - }; |
---|
1110 | | - |
---|
1111 | | - fusb30x { |
---|
1112 | | - fusb0_int: fusb0-int { |
---|
1113 | | - rockchip,pins = |
---|
1114 | | - <1 RK_PA2 RK_FUNC_GPIO &pcfg_pull_up>; |
---|
1115 | 1179 | }; |
---|
1116 | 1180 | }; |
---|
1117 | 1181 | |
---|
.. | .. |
---|
1205 | 1269 | }; |
---|
1206 | 1270 | }; |
---|
1207 | 1271 | |
---|
| 1272 | + usb-typec { |
---|
| 1273 | + usbc0_int: usbc0-int { |
---|
| 1274 | + rockchip,pins = <1 RK_PA2 RK_FUNC_GPIO &pcfg_pull_up>; |
---|
| 1275 | + }; |
---|
| 1276 | + |
---|
| 1277 | + vcc5v0_typec0_en: vcc5v0-typec0-en { |
---|
| 1278 | + rockchip,pins = <1 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>; |
---|
| 1279 | + }; |
---|
| 1280 | + }; |
---|
| 1281 | + |
---|
1208 | 1282 | wireless-bluetooth { |
---|
1209 | 1283 | bt_irq_gpio: bt-irq-gpio { |
---|
1210 | 1284 | rockchip,pins = |
---|