hc
2024-08-09 3d911568f3069a842249d4de3843d281d5af84d6
kernel/arch/arm64/boot/dts/rockchip/NK-6A13_V0A.dtsi
....@@ -38,10 +38,10 @@
3838 io-channels = <&saradc 3>;
3939 io-channel-names = "adc-detect";
4040 keyup-threshold-microvolt = <1800000>;
41
- pinctrl-0 = <&hp_det>;
41
+ pinctrl-0 = <&spk_con>;
4242 pinctrl-names = "default";
43
- hp-det-gpio = <&gpio1 RK_PD5 GPIO_ACTIVE_HIGH>;
44
- spk-con-gpio = <&gpio3 RK_PC3 GPIO_ACTIVE_HIGH>;
43
+ //hp-det-gpio = <&gpio1 RK_PD5 GPIO_ACTIVE_LOW>;
44
+ //spk-con-gpio = <&gpio3 RK_PC3 GPIO_ACTIVE_HIGH>;
4545 play-pause-key {
4646 label = "playpause";
4747 linux,code = <164>;
....@@ -132,9 +132,10 @@
132132 };
133133
134134 rk_headset: rk-headset {
135
- status = "disabled";
135
+ status = "okay";
136136 compatible = "rockchip_headset";
137
- headset_gpio = <&gpio1 RK_PD5 GPIO_ACTIVE_LOW>;
137
+ headset_gpio = <&gpio1 RK_PD5 GPIO_ACTIVE_HIGH>;//HP_DET_L_GPIO3_D5_d_3V3
138
+ spk_ctl_gpio = <&gpio4 RK_PB4 GPIO_ACTIVE_LOW>;//SPK_CTL_GPIO4_B4_u_3V3
138139 pinctrl-names = "default";
139140 pinctrl-0 = <&hp_det>;
140141 io-channels = <&saradc 3>;
....@@ -158,9 +159,20 @@
158159 regulator-boot-on;
159160 enable-active-high;
160161 //gpio = <&gpio1 RK_PD2 GPIO_ACTIVE_HIGH>;
161
- gpio = <&gpio0 RK_PC0 GPIO_ACTIVE_HIGH>;
162
+ gpio = <&gpio1 RK_PC4 GPIO_ACTIVE_HIGH>;
162163 vin-supply = <&vcc_1v8_s0>;
163164 };
165
+
166
+ vcc3v3_lcd1_n: vcc3v3-lcd1-n {
167
+ compatible = "regulator-fixed";
168
+ regulator-name = "vcc3v3_lcd1_n";
169
+ regulator-boot-on;
170
+ regulator-min-microvolt = <3300000>;
171
+ regulator-max-microvolt = <3300000>;
172
+ enable-active-high;
173
+ gpio = <&gpio1 RK_PC4 GPIO_ACTIVE_HIGH>;
174
+ };
175
+
164176
165177 vcc3v3_pcie30: vcc3v3-pcie30 {
166178 compatible = "regulator-fixed";
....@@ -242,7 +254,7 @@
242254 wifi_chip_type = "ap6398s";
243255 pinctrl-names = "default";
244256 pinctrl-0 = <&wifi_host_wake_irq>;
245
- WIFI,host_wake_irq = <&gpio0 RK_PB2 GPIO_ACTIVE_HIGH>; //WIFI_WAKE_HOST_H
257
+ WIFI,host_wake_irq = <&gpio2 RK_PB5 GPIO_ACTIVE_HIGH>; //GPIO2_B5_u_1V8_WF-BT_WAKEUP_IN
246258 // WIFI,poweren_gpio = <&gpio0 RK_PC4 GPIO_ACTIVE_HIGH>;
247259 status = "okay";
248260 };
....@@ -252,57 +264,45 @@
252264 pinctrl-names = "default";
253265 pinctrl-0 = <&ndj_io_gpio>;
254266
255
-// vcc_5v {
256
-// gpio_num = <&gpio4 RK_PB2 GPIO_ACTIVE_HIGH>;
257
-// gpio_function = <0>;
258
-// };
267
+ usb_power {
268
+ gpio_num = <&gpio4 RK_PB0 GPIO_ACTIVE_HIGH>;
269
+ gpio_function = <0>;
270
+ };//USB_HOST_PWREN_H
259271
260272 vcc_12v {
261
- gpio_num = <&gpio1 RK_PB5 GPIO_ACTIVE_HIGH>;
273
+ gpio_num = <&gpio0 RK_PD3 GPIO_ACTIVE_HIGH>;
262274 gpio_function = <0>;
263
- };
275
+ };//VCC12_IO_EN_GPIO0_D3_u_3V3
264276
265277 vcc_3v {
266
- gpio_num = <&gpio0 RK_PC0 GPIO_ACTIVE_HIGH>;
278
+ gpio_num = <&gpio4 RK_PA1 GPIO_ACTIVE_HIGH>;
267279 gpio_function = <0>;
268
- };
280
+ };//VCC3_IO_EN_GPIO4_A1_d_3V3
269281
270282 hub_5V_reset {
271
- gpio_num = <&gpio4 RK_PB3 GPIO_ACTIVE_HIGH>;
283
+ gpio_num = <&gpio4 RK_PB6 GPIO_ACTIVE_HIGH>;
272284 gpio_function = <3>;
273
- };
285
+ };//HUB_RESET_GPIO4_B6_d_3V3
274286
275287 4g_power {
276
- gpio_num = <&gpio1 RK_PB6 GPIO_ACTIVE_HIGH>;
288
+ gpio_num = <&gpio0 RK_PC6 GPIO_ACTIVE_HIGH>;
277289 gpio_function = <0>;
278
- };
290
+ };//4G_PWREN_GPIO3_C7_u_3V3
279291
280
- wake_4g {
281
- gpio_num = <&gpio2 RK_PB5 GPIO_ACTIVE_LOW>;
282
- gpio_function = <0>;
283
- };
292
+// wake_4g {
293
+// gpio_num = <&gpio2 RK_PB5 GPIO_ACTIVE_LOW>;
294
+// gpio_function = <0>;
295
+// };//GPIO2_B5_u_1V8_WF-BT_WAKEUP_IN
284296
285297 air_mode_4g {
286298 gpio_num = <&gpio2 RK_PB4 GPIO_ACTIVE_LOW>;
287299 gpio_function = <0>;
288
- };
300
+ }; //GPIO2_B4_u_1V8_4G_AIR_MODE_IN
289301
290302 reset_4g {
291303 gpio_num = <&gpio2 RK_PC3 GPIO_ACTIVE_LOW>;
292304 gpio_function = <3>;
293
- };
294
-/*
295
- spk_ctl {
296
- gpio_num = <&gpio3 RK_PC3 GPIO_ACTIVE_LOW>;
297
- gpio_function = <0>;
298
- };
299
-
300
- hp_det
301
- {
302
- gpio_num = <&gpio1 RK_PD5 GPIO_ACTIVE_LOW>;
303
- gpio_function = <1>;
304
- };
305
-*/
305
+ }; //GPIO2_C3_d_1V8_4G_RESET_N_IN
306306 };
307307
308308
....@@ -310,12 +310,11 @@
310310 compatible = "simple-panel";
311311 backlight = <&backlight>;
312312 power-supply = <&vcc3v3_lcd_n>;
313
- vcc-5v-gpio = <&gpio4 RK_PB2 GPIO_ACTIVE_HIGH>;
314
- vddio-mipi = <&gpio1 RK_PB2 GPIO_ACTIVE_HIGH>; //MIPIDIS_PWR_EN_1V8
315
- enable-gpios = <&gpio3 RK_PD2 GPIO_ACTIVE_HIGH>; //LCD_VDD_EN
316
- reset-gpios = <&gpio1 RK_PA1 GPIO_ACTIVE_LOW>; //CH7511_RESET_N_1V8
317
- edp-bl-gpios = <&gpio3 RK_PC6 GPIO_ACTIVE_HIGH>; //LCD_BLK-PWR_EN
318
- edp-bl-en = <&gpio3 RK_PD4 GPIO_ACTIVE_HIGH>; //LCD_BKL_EN_GPIO3_D4_d_3V3
313
+ vcc-5v-gpio = <&gpio4 RK_PB5 GPIO_ACTIVE_HIGH>; //VCC5_IO_EN_GPIO4_B5_d_3V3
314
+ enable-gpios = <&gpio3 RK_PC6 GPIO_ACTIVE_HIGH>; //LCD_VDD_EN_GPIO3_C6_u_3V3
315
+ reset-gpios = <&gpio1 RK_PB5 GPIO_ACTIVE_LOW>; //CH7511_RESET_N_1V8
316
+ edp-bl-gpios = <&gpio3 RK_PB2 GPIO_ACTIVE_HIGH>; //LCD_BKL_PWM3_3V3
317
+ edp-bl-en = <&gpio3 RK_PA6 GPIO_ACTIVE_HIGH>; //LCD_BKL_EN_GPIO3_A6_d_3V3
319318 bus-format = <MEDIA_BUS_FMT_RGB888_1X24>;
320319 bpc = <8>;
321320 prepare-delay-ms = <200>;
....@@ -386,9 +385,22 @@
386385 status = "okay";
387386 };
388387
388
+&backlight1 {
389
+ pwms = <&pwm11 0 25000 0>;
390
+ status = "okay";
391
+};
392
+
389393 &combphy0_ps {
390394 status = "okay";
391395 };
396
+
397
+/*
398
+&usbdrd_dwc3_0 {
399
+ dr_mode = "otg";
400
+ extcon = <&u2phy0>;
401
+ status = "okay";
402
+};
403
+*/
392404
393405 &combphy1_ps {
394406 status = "okay";
....@@ -423,8 +435,12 @@
423435 * mipi_dcphy0 needs to be enabled
424436 * when dsi0 is enabled
425437 */
438
+&mipi_dcphy0 {
439
+ status = "okay";
440
+};
441
+
426442 &dsi0 {
427
- status = "disabled";
443
+ status = "okay";
428444 };
429445
430446 &dsi0_in_vp2 {
....@@ -432,12 +448,14 @@
432448 };
433449
434450 &dsi0_in_vp3 {
435
- status = "disabled";
451
+ status = "okay";
436452 };
437453
438454 &dsi0_panel {
439
- power-supply = <&vcc3v3_lcd_n>;
440
- reset-gpios = <&gpio0 RK_PD3 GPIO_ACTIVE_LOW>;
455
+ power-supply = <&vcc3v3_lcd1_n>; //LCD_PWREN_H
456
+ vcc-5v-gpio = <&gpio4 RK_PB2 GPIO_ACTIVE_HIGH>;
457
+ reset-gpios = <&gpio1 RK_PA0 GPIO_ACTIVE_LOW>; //MIPIDIS_RST_GPIO1_A0_d_1V8
458
+ vddio-mipi = <&gpio1 RK_PB2 GPIO_ACTIVE_HIGH>; //MIPIDIS_PWR_EN_1V8
441459 pinctrl-names = "default";
442460 pinctrl-0 = <&lcd_rst_gpio>;
443461 };
....@@ -493,7 +511,7 @@
493511 /* rx_delay = <0x3f>; */
494512
495513 phy-handle = <&rgmii_phy>;
496
- status = "disabled";
514
+ status = "okay";
497515 };
498516
499517 &hdmi0 {
....@@ -700,6 +718,12 @@
700718 compatible = "atmel,24c256";
701719 reg = <0x50>;
702720 };
721
+
722
+ eeprom@53 {
723
+ //compatible = "atmel,24c02";
724
+ compatible = "atmel,24c256";
725
+ reg = <0x53>;
726
+ };
703727 #if 0
704728 usbc0: fusb302@22 {
705729 compatible = "fcs,fusb302";
....@@ -824,9 +848,7 @@
824848 };
825849 };
826850
827
-&mipi_dcphy0 {
828
- status = "okay";
829
-};
851
+
830852
831853 &mipi_dcphy1 {
832854 status = "disabled";
....@@ -834,21 +856,21 @@
834856
835857 &pcie2x1l2 {
836858 phys = <&combphy0_ps PHY_TYPE_PCIE>;
837
- reset-gpios = <&gpio3 RK_PD1 GPIO_ACTIVE_HIGH>;
859
+ reset-gpios = <&gpio3 RK_PD0 GPIO_ACTIVE_HIGH>;//PCIE20x1_2_RSTn_GPIO3_D0_3V3
838860 vpcie3v3-supply = <&vcc3v3_pcie30>;
839861 status = "okay";
840862 };//MINIPCIE
841863
842864 &pcie2x1l1 {
843865 phys = <&combphy2_psu PHY_TYPE_PCIE>;
844
- reset-gpios = <&gpio4 RK_PA5 GPIO_ACTIVE_HIGH>;
866
+ reset-gpios = <&gpio4 RK_PA2 GPIO_ACTIVE_HIGH>;//PCIEX1_1_PERSTn_M1_L
845867 vpcie3v3-supply = <&vcc3v3_pcie30>;
846868 status = "okay";
847869 };//M.2 WIFI6
848870
849871 &pcie2x1l0 {
850872 phys = <&combphy1_ps PHY_TYPE_PCIE>;
851
- reset-gpios = <&gpio4 RK_PA2 GPIO_ACTIVE_HIGH>;
873
+ reset-gpios = <&gpio4 RK_PA5 GPIO_ACTIVE_HIGH>; //PCIEx1_0_PERSTn_M1_L
852874 vpcie3v3-supply = <&vcc3v3_pcie30>;
853875 status = "okay";
854876 };//RTL8111H
....@@ -901,6 +923,10 @@
901923 hp_det: hp-det {
902924 rockchip,pins = <1 RK_PD5 RK_FUNC_GPIO &pcfg_pull_none>;
903925 };
926
+
927
+ spk_con: spk-con {
928
+ rockchip,pins = <4 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>;
929
+ };
904930 };
905931
906932 hym8563 {
....@@ -911,7 +937,7 @@
911937
912938 lcd {
913939 lcd_rst_gpio: lcd-rst-gpio {
914
- rockchip,pins = <0 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>;
940
+ rockchip,pins = <1 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>;
915941 };
916942 };
917943
....@@ -976,22 +1002,22 @@
9761002 ndj_io_init{
9771003 ndj_io_gpio: ndj_io_gpio_col{
9781004 rockchip,pins =
979
- <1 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>,
980
- <0 RK_PC0 RK_FUNC_GPIO &pcfg_pull_none>,
981
- <4 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>,
982
- <1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_none>,
983
- <2 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>,
1005
+ <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>,
1006
+ <0 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>,
1007
+ <4 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none>,
1008
+ <4 RK_PB6 RK_FUNC_GPIO &pcfg_pull_none>,
1009
+ <0 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>,
9841010 <2 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>,
9851011 <2 RK_PC3 RK_FUNC_GPIO &pcfg_pull_none>,
986
- <4 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>, //vcc_5v
987
- <4 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>, //GPIO4_B5_d_3V3
988
- <4 RK_PB6 RK_FUNC_GPIO &pcfg_pull_none>, //GPIO4_B6_d_3V3
989
- <3 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>, //GPIO3_B0_u_3V3
990
- <3 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>, //GPIO3_B2_d_3V3
991
- <3 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>, //GPIO3_B3_u_3V3
992
- <3 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>, //GPIO3_B4_u_3V3
993
- <3 RK_PA7 RK_FUNC_GPIO &pcfg_pull_none>, //GPIO3_A7_u_3V3
994
- <3 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>; //GPIO3_A0_u_3V3
1012
+ <4 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>, //vcc_5v
1013
+ <1 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>, //SPI0_MISO_M2_1V8
1014
+ <1 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>, //SPI0_MISO_M2_1V8
1015
+ <1 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>, //SPI0_CLK_M2_1V8
1016
+ <1 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>, //SPI0_CS0_M2_1V8
1017
+ <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>, //SPI4_MISO_M2_1V8
1018
+ <0 RK_PA1 RK_FUNC_GPIO &pcfg_pull_none>, //SPI4_MOSI_M2_1V8
1019
+ <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>, //GPIO3_A7_u_3V3
1020
+ <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>; //GPIO3_A0_u_3V3
9951021
9961022 };
9971023 };
....@@ -1014,6 +1040,11 @@
10141040 &pwm10 {
10151041 status = "okay";
10161042 pinctrl-0 = <&pwm10m2_pins>;
1043
+};
1044
+
1045
+&pwm11 {
1046
+ status = "okay";
1047
+ pinctrl-0 = <&pwm11m3_pins>;
10171048 };
10181049
10191050 &route_hdmi0 {
....@@ -1050,14 +1081,9 @@
10501081 vmmc-supply = <&vcc_3v3_sd_s0>;
10511082 };
10521083
1053
-&uart9 {
1054
- status = "okay";
1055
- pinctrl-names = "default";
1056
- pinctrl-0 = <&uart9m0_xfer &uart9m0_ctsn>;
1057
-};
1058
-
10591084 &u2phy0_otg {
10601085 status = "okay";
1086
+ phy-supply = <&vcc5v0_host>;
10611087 };
10621088
10631089 &u2phy1_otg {
....@@ -1071,7 +1097,7 @@
10711097 &u2phy3_host {
10721098 phy-supply = <&vcc5v0_host>;
10731099 };
1074
-
1100
+#if 0
10751101 &usbdp_phy0 {
10761102 rockchip,dp-lane-mux = <2 3>;
10771103 status = "okay";
....@@ -1099,17 +1125,12 @@
10991125 status = "okay";
11001126 };
11011127
1102
-&usbdrd_dwc3_0 {
1103
- dr_mode = "otg";
1104
- extcon = <&u2phy0>;
1105
- status = "okay";
1106
-};
1107
-
11081128 &usbdrd_dwc3_1 {
11091129 dr_mode = "host";
11101130 maximum-speed = "high-speed";
11111131 status = "okay";
11121132 };
1133
+#endif
11131134
11141135 &uart1 {
11151136 status = "okay";
....@@ -1119,7 +1140,7 @@
11191140 };
11201141
11211142 &uart3 {
1122
- status = "okay";
1143
+ status = "disabled";
11231144 pinctrl-names = "default";
11241145 pinctrl-0 = <&uart3m1_xfer>;
11251146 };
....@@ -1150,7 +1171,7 @@
11501171 };
11511172
11521173 &uart8 {
1153
- status = "okay";
1174
+ status = "disabled";
11541175 pinctrl-names = "default";
11551176 pinctrl-0 = <&uart8m1_xfer>;
11561177 };