forked from ~ljy/RK356X_SDK_RELEASE

hc
2023-11-20 69d6da3c1c63675524a25e7dc92a4f43c4164cef
kernel/arch/arm64/boot/dts/rockchip/NK-R36S0.dtsi
....@@ -16,14 +16,6 @@
1616 model = "Rockchip RK3568 EVB1 DDR4 V10 Board";
1717 compatible = "rockchip,rk3568-evb1-ddr4-v10", "rockchip,rk3568";
1818
19
- rk_headset: rk-headset {
20
- compatible = "rockchip_headset";
21
- headset_gpio = <&gpio0 RK_PD5 GPIO_ACTIVE_LOW>;
22
- spk_ctl_gpio = <&gpio4 RK_PC2 GPIO_ACTIVE_LOW>;//AMP_SD_GPIO4_C2_3V3
23
- pinctrl-names = "default";
24
- pinctrl-0 = <&hp_det>;
25
- };
26
-
2719 vcc2v5_sys: vcc2v5-ddr {
2820 compatible = "regulator-fixed";
2921 regulator-name = "vcc2v5-sys";
....@@ -34,6 +26,15 @@
3426 vin-supply = <&vcc3v3_sys>;
3527 };
3628
29
+ vcc3v3_vga: vcc3v3-vga {
30
+ compatible = "regulator-fixed";
31
+ regulator-name = "vcc3v3_vga";
32
+ regulator-always-on;
33
+ regulator-boot-on;
34
+ gpio = <&gpio0 RK_PD5 GPIO_ACTIVE_HIGH>;
35
+ enable-active-high;
36
+ vin-supply = <&vcc3v3_sys>;
37
+ };
3738
3839 pcie30_avdd0v9: pcie30-avdd0v9 {
3940 compatible = "regulator-fixed";
....@@ -60,9 +61,7 @@
6061 regulator-name = "vcc3v3_pcie";
6162 regulator-min-microvolt = <3300000>;
6263 regulator-max-microvolt = <3300000>;
63
- regulator-always-on;
6464 enable-active-high;
65
- regulator-boot-on;
6665 gpio = <&gpio0 RK_PD4 GPIO_ACTIVE_HIGH>;
6766 startup-delay-us = <5000>;
6867 vin-supply = <&dc_12v>;
....@@ -87,8 +86,9 @@
8786 enable-active-high;
8887 regulator-always-on;
8988 regulator-boot-on;
90
- };
89
+ };
9190 #endif
91
+
9292 ndj_io_init {
9393 compatible = "nk_io_control";
9494 pinctrl-names = "default";
....@@ -145,28 +145,50 @@
145145 gpio_num = <&gpio3 RK_PC6 GPIO_ACTIVE_HIGH>; //WIFI_PWREN_GPIO3_C6_1V8
146146 gpio_function = <0>;
147147 };
148
- };
149
-#if 0
150
- nk_io_init {
151
- compatible = "nk_io_control";
152
-// vcc3_io_en_gpio = <&gpio0 RK_PC4 GPIO_ACTIVE_HIGH>; //VCC3_IO_EN_GPIO0_C4_3V3
153
- hub_host2_5V_rest_gpio = <&gpio4 RK_PD2 GPIO_ACTIVE_HIGH>; //HUB_RST_GPIO4_D2_3V3
154
- hub_host3_5v_gpio = <&gpio4 RK_PB2 GPIO_ACTIVE_HIGH>; //HOST3_EN_GPIO4_B2_1V8
155
- vcc_5v_io = <&gpio1 RK_PA4 GPIO_ACTIVE_HIGH>; //VCC5_IO_EN_GPIO1_A4_3V3
156
- vcc_12v_io = <&gpio0 RK_PC7 GPIO_ACTIVE_HIGH>; //VCC12_IO_EN_GPIO0_C7_3V3
157
- en_4g_gpio = <&gpio0 RK_PC6 GPIO_ACTIVE_HIGH>; //4G_PWREN_H_GPIO0_C6
158
- reset_4g_gpio = <&gpio1 RK_PB2 GPIO_ACTIVE_HIGH>; //4G_RST_GPIO01_B2_3V3
159
- air_mode_4g_gpio = <&gpio1 RK_PB0 GPIO_ACTIVE_HIGH>; //4G_AIR_MODE_GPIO01_B0_3V3
160
- wake_4g_gpio = <&gpio1 RK_PB1 GPIO_ACTIVE_HIGH>; //4G_WAKEUP_GPIO01_B1_3V3
161
- hp_en_gpio = <&gpio3 RK_PA6 GPIO_ACTIVE_HIGH>;//HP_EN_GPIO3_A6_3V3
162
-// spk_out_gpio = <&gpio4 RK_PC2 GPIO_ACTIVE_HIGH>;//AMP_SD_GPIO4_C2_3V3
163
- wifi_power_en_gpio = <&gpio3 RK_PC6 GPIO_ACTIVE_HIGH>; //WIFI_PWREN_GPIO3_C6_1V8
164
-// pcie_power_en_gpio = <&gpio0 RK_PD4 GPIO_ACTIVE_HIGH>;//PCIE_PWREN_H_GPIO0_D4
165
- pinctrl-names = "default";
166
- pinctrl-0 = <&nk_io_gpio>;
167
- };
168
-#endif
169
- panel: panel {
148
+ #if 0
149
+ do1 {
150
+ gpio_num = <&gpio1 RK_PD0 GPIO_ACTIVE_LOW>;
151
+ gpio_function = <0>;
152
+ };
153
+
154
+ do2 {
155
+ gpio_num = <&gpio1 RK_PD2 GPIO_ACTIVE_HIGH>;
156
+ gpio_function = <0>;
157
+ };
158
+
159
+ do3 {
160
+ gpio_num = <&gpio1 RK_PD1 GPIO_ACTIVE_HIGH>;
161
+ gpio_function = <0>;
162
+ };
163
+
164
+ do4 {
165
+ gpio_num = <&gpio1 RK_PD3 GPIO_ACTIVE_HIGH>;
166
+ gpio_function = <0>;
167
+ };
168
+
169
+ do5 {
170
+ gpio_num = <&gpio2 RK_PD6 GPIO_ACTIVE_LOW>;
171
+ gpio_function = <0>;
172
+ };
173
+
174
+ do6 {
175
+ gpio_num = <&gpio2 RK_PD7 GPIO_ACTIVE_LOW>;
176
+ gpio_function = <0>;
177
+ };
178
+
179
+ do7 {
180
+ gpio_num = <&gpio3 RK_PA0 GPIO_ACTIVE_LOW>;
181
+ gpio_function = <0>;
182
+ };
183
+
184
+ di1 {
185
+ gpio_num = <&gpio2 RK_PD5 GPIO_ACTIVE_HIGH>;
186
+ gpio_function = <1>;
187
+ };
188
+ #endif
189
+ };
190
+
191
+ panel: panel {
170192 compatible = "simple-panel";
171193 backlight = <&backlight>;
172194 power-supply = <&vcc3v3_lcd0_n>;
....@@ -270,10 +292,6 @@
270292 * video_phy0 needs to be enabled
271293 * when dsi0 is enabled
272294 */
273
-&video_phy0 {
274
- status = "disabled";
275
-};
276
-
277295 &dsi0 {
278296 status = "disabled";
279297 };
....@@ -294,10 +312,6 @@
294312 * video_phy1 needs to be enabled
295313 * when dsi1 is enabled
296314 */
297
-
298
-&video_phy1 {
299
- status = "okay";
300
-};
301315 &dsi1 {
302316 status = "disabled";
303317 };
....@@ -307,29 +321,15 @@
307321 };
308322
309323 &dsi1_in_vp1 {
310
- status = "okay";
324
+ status = "disabled";
311325 };
312326
313327 &dsi1_panel {
314
- power-supply = <&vcc3v3_lcd1_n>; //MIPI_3V3EN_GPIO3_A3_d_3V3
315
- vddio-mipi = <&gpio3 RK_PA4 GPIO_ACTIVE_HIGH>; //MIPI_EN_1V8_GPIO3_A4_d_3V3
316
- reset-gpios = <&gpio3 RK_PC7 GPIO_ACTIVE_LOW>; //MIPI_RST_L_GPIO3_C7
317
- vcc-5v-gpio = <&gpio1 RK_PA4 GPIO_ACTIVE_HIGH>; //VCC5_IO_EN_GPIO1_A4_3V3
318
- pinctrl-names = "default";
319
- pinctrl-0 = <&lcd1_rst_gpio>;
328
+ power-supply = <&vcc3v3_lcd1_n>;
320329 };
321
-
322
-&route_dsi1 {
323
- status = "disabled";
324
- connect = <&vp1_out_dsi1>;
325
-};
326
-
327
-
328
-/*
329
-* edp_start
330
-*/
331330
332331 &edp {
332
+ //hpd-gpios = <&gpio0 RK_PC2 GPIO_ACTIVE_HIGH>;
333333 force-hpd;
334334 status = "okay";
335335 ports {
....@@ -339,70 +339,21 @@
339339 remote-endpoint = <&panel_in>;
340340 };
341341 };
342
- };
342
+
343
+ };
343344 };
344345
345346 &edp_phy {
346
- status = "okay";
347
-
347
+ status = "okay";
348348 };
349349
350350 &edp_in_vp0 {
351
- status = "disabled";
352
-};
353
-
354
-&edp_in_vp1 {
355
- status = "okay";
356
-
357
-};
358
-
359
-&route_edp {
360
- status = "okay";
361
- connect = <&vp1_out_edp>;
362
-};
363
-
364
-&route_edp {
365
- status = "okay";
366
-};
367
-/*
368
-* edp_end
369
-*/
370
-
371
-/*
372
-* Hdmi_start
373
-*/
374
-
375
-&hdmi {
376
- status = "okay";
377
- rockchip,phy-table =
378
- <92812500 0x8009 0x0000 0x0270>,
379
- <165000000 0x800b 0x0000 0x026d>,
380
- <185625000 0x800b 0x0000 0x01ed>,
381
- <297000000 0x800b 0x0000 0x01ad>,
382
- <594000000 0x8029 0x0000 0x0088>,
383
- <000000000 0x0000 0x0000 0x0000>;
384
-};
385
-
386
-&route_hdmi {
387
- status = "okay";
388
- connect = <&vp0_out_hdmi>;
389
-};
390
-
391
-&hdmi_in_vp0 {
392
- status = "okay";
393
-};
394
-
395
-&hdmi_in_vp1 {
396351 status = "disabled";
397352 };
398353
399
-&hdmi_sound {
354
+&edp_in_vp1 {
400355 status = "okay";
401356 };
402
-
403
-/*
404
- * Hdmi_END
405
-*/
406357
407358 &gmac0 {
408359 phy-mode = "rgmii";
....@@ -462,9 +413,7 @@
462413 * power-supply should switche to vcc3v3_lcd1_n
463414 * when mipi panel is connected to dsi1.
464415 */
465
-&gt1x {
466
- power-supply = <&vcc3v3_lcd0_n>;
467
-};
416
+
468417
469418 &i2c3 {
470419 status = "okay";
....@@ -483,7 +432,7 @@
483432 };
484433
485434 &i2c4 {
486
- status = "okay";
435
+ status = "disabled";
487436 gc8034: gc8034@37 {
488437 compatible = "galaxycore,gc8034";
489438 status = "okay";
....@@ -529,7 +478,7 @@
529478 };
530479 };
531480 ov5695: ov5695@36 {
532
- status = "okay";
481
+ status = "disabled";
533482 compatible = "ovti,ov5695";
534483 reg = <0x36>;
535484 clocks = <&cru CLK_CIF_OUT>;
....@@ -552,19 +501,6 @@
552501 };
553502 };
554503
555
-&i2c5 {
556
- status = "okay";
557
-
558
- hym8563: hym8563@51 {
559
- compatible = "haoyu,hym8563";
560
- reg = <0x51>;
561
- #clock-cells = <0>;
562
- clock-frequency = <32768>;
563
- clock-output-names = "xin32k";
564
- /* rtc_int is not connected */
565
- };
566
-};
567
-
568504 &mdio0 {
569505 rgmii_phy0: phy@0 {
570506 compatible = "ethernet-phy-ieee802.3-c22";
....@@ -579,10 +515,16 @@
579515 };
580516 };
581517
518
+&video_phy0 {
519
+ status = "disabled";
520
+};
582521
522
+&video_phy1 {
523
+ status = "disabled";
524
+};
583525
584526 &pcie30phy {
585
- status = "okay";
527
+ status = "disabled";
586528 };
587529
588530 &pcie2x1 {
....@@ -591,24 +533,23 @@
591533 status = "okay";
592534 };
593535
536
+&pcie3x2 {
537
+ reset-gpios = <&gpio2 RK_PD6 GPIO_ACTIVE_HIGH>;
538
+ vpcie3v3-supply = <&vcc3v3_pcie>;
539
+ status = "okay";
540
+};
541
+
594542 &pinctrl {
595
-// cam {
596
-// camera_pwr: camera-pwr {
597
-// rockchip,pins =
598
-// /* camera power en */
599
-// <0 RK_PC1 RK_FUNC_GPIO &pcfg_pull_none>;
600
-// };
601
-// };
543
+
602544 headphone {
603545 hp_det: hp-det {
604
- rockchip,pins = <0 RK_PD5 RK_FUNC_GPIO &pcfg_pull_down>,
605
- <4 RK_PC2 RK_FUNC_GPIO &pcfg_pull_down>;
546
+ rockchip,pins = <3 RK_PC2 RK_FUNC_GPIO &pcfg_pull_down>;
606547 };
607548 };
608549
609550 wireless-wlan {
610551 wifi_host_wake_irq: wifi-host-wake-irq {
611
- rockchip,pins = <2 RK_PB2 RK_FUNC_GPIO &pcfg_pull_down>;
552
+ rockchip,pins = <3 RK_PD4 RK_FUNC_GPIO &pcfg_pull_down>;
612553 };
613554 };
614555
....@@ -618,12 +559,6 @@
618559 };
619560 };
620561
621
- lcd1 {
622
- lcd1_rst_gpio: lcd1-rst-gpio {
623
- rockchip,pins = <3 RK_PC7 RK_FUNC_GPIO &pcfg_pull_none>;
624
- };
625
- };
626
-
627562 nk_io_init{
628563 nk_io_gpio: nk-io-gpio{
629564 rockchip,pins = <0 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>,
....@@ -633,7 +568,7 @@
633568 <4 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>,
634569 <1 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>,
635570 <0 RK_PC7 RK_FUNC_GPIO &pcfg_pull_none>,
636
- <1 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>,
571
+ <1 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>,
637572 <1 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>,
638573 <1 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>,
639574 <3 RK_PA6 RK_FUNC_GPIO &pcfg_pull_none>,
....@@ -649,6 +584,10 @@
649584 <0 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>;
650585 };
651586 };
587
+};
588
+
589
+&rk809_sound {
590
+ hp-det-gpio = <&gpio3 RK_PC2 GPIO_ACTIVE_LOW>;
652591 };
653592
654593 &rkisp {
....@@ -673,32 +612,36 @@
673612 };
674613 };
675614
615
+&route_dsi0 {
616
+ status = "disabled";
617
+ connect = <&vp1_out_dsi0>;
618
+};
676619
677620
678621
622
+&route_edp {
623
+ status = "okay";
624
+ connect = <&vp1_out_edp>;
625
+};
679626
680627 &sata2 {
681628 status = "okay";
682629 };
683630
684631 &sdmmc2 {
685
- status = "disabled";
686
-};
687
-
688
-&sdmmc1 {
689
- max-frequency = <150000000>;
690
- supports-sdio;
691
- bus-width = <4>;
692
- disable-wp;
693
- cap-sd-highspeed;
694
- cap-sdio-irq;
695
- keep-power-in-suspend;
696
- mmc-pwrseq = <&sdio_pwrseq>;
697
- non-removable;
698
- pinctrl-names = "default";
699
- pinctrl-0 = <&sdmmc1_bus4 &sdmmc1_cmd &sdmmc1_clk>;
700
- sd-uhs-sdr104;
701
- status = "okay";
632
+ max-frequency = <150000000>;
633
+ supports-sdio;
634
+ bus-width = <4>;
635
+ disable-wp;
636
+ cap-sd-highspeed;
637
+ cap-sdio-irq;
638
+ keep-power-in-suspend;
639
+ mmc-pwrseq = <&sdio_pwrseq>;
640
+ non-removable;
641
+ pinctrl-names = "default";
642
+ pinctrl-0 = <&sdmmc2m0_bus4 &sdmmc2m0_cmd &sdmmc2m0_clk>;
643
+ sd-uhs-sdr104;
644
+ status = "okay";
702645 };
703646
704647 &spdif_8ch {
....@@ -739,8 +682,8 @@
739682 pinctrl-0 = <&uart1m0_rtsn>;
740683 pinctrl-1 = <&uart1_gpios>;
741684 BT,reset_gpio = <&gpio2 RK_PB7 GPIO_ACTIVE_HIGH>;
742
- BT,wake_gpio = <&gpio2 RK_PC0 GPIO_ACTIVE_HIGH>;
743
- BT,wake_host_irq = <&gpio2 RK_PC1 GPIO_ACTIVE_HIGH>;
685
+ BT,wake_gpio = <&gpio2 RK_PC0 GPIO_ACTIVE_HIGH>;
686
+ BT,wake_host_irq = <&gpio2 RK_PC1 GPIO_ACTIVE_HIGH>;
744687 status = "okay";
745688 };
746689
....@@ -777,4 +720,4 @@
777720 &uart9 {
778721 status = "okay";
779722 pinctrl-0 = <&uart9m1_xfer>;
780
-};
723
+};