xref: /linux/arch/arm64/boot/dts/rockchip/rk3588-nanopc-t6.dtsi (revision 3fd6c59042dbba50391e30862beac979491145fe)
1// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2/*
3 * Copyright (c) 2021 Rockchip Electronics Co., Ltd.
4 * Copyright (c) 2023 Thomas McKahan
5 *
6 */
7
8/dts-v1/;
9
10#include <dt-bindings/gpio/gpio.h>
11#include <dt-bindings/input/input.h>
12#include <dt-bindings/pinctrl/rockchip.h>
13#include <dt-bindings/soc/rockchip,vop2.h>
14#include <dt-bindings/usb/pd.h>
15#include "rk3588.dtsi"
16
17/ {
18	model = "FriendlyElec NanoPC-T6";
19	compatible = "friendlyarm,nanopc-t6", "rockchip,rk3588";
20
21	aliases {
22		mmc0 = &sdhci;
23		mmc1 = &sdmmc;
24	};
25
26	adc-keys-0 {
27		compatible = "adc-keys";
28		io-channels = <&saradc 0>;
29		io-channel-names = "buttons";
30		keyup-threshold-microvolt = <1800000>;
31		poll-interval = <100>;
32
33		button-maskrom {
34			label = "Mask Rom";
35			linux,code = <KEY_SETUP>;
36			press-threshold-microvolt = <2000>;
37		};
38	};
39
40	chosen {
41		stdout-path = "serial2:1500000n8";
42	};
43
44	hdmi0-con {
45		compatible = "hdmi-connector";
46		type = "a";
47
48		port {
49			hdmi0_con_in: endpoint {
50				remote-endpoint = <&hdmi0_out_con>;
51			};
52		};
53	};
54
55	ir-receiver {
56		compatible = "gpio-ir-receiver";
57		gpios = <&gpio0 RK_PD4 GPIO_ACTIVE_LOW>;
58		pinctrl-names = "default";
59		pinctrl-0 = <&ir_receiver_pin>;
60	};
61
62	leds {
63		compatible = "gpio-leds";
64
65		sys_led: led-0 {
66			gpios = <&gpio2 RK_PB7 GPIO_ACTIVE_HIGH>;
67			label = "system-led";
68			linux,default-trigger = "heartbeat";
69			pinctrl-names = "default";
70			pinctrl-0 = <&sys_led_pin>;
71		};
72
73		usr_led: led-1 {
74			gpios = <&gpio2 RK_PC0 GPIO_ACTIVE_HIGH>;
75			label = "user-led";
76			pinctrl-names = "default";
77			pinctrl-0 = <&usr_led_pin>;
78		};
79	};
80
81	sound {
82		compatible = "simple-audio-card";
83		pinctrl-names = "default";
84		pinctrl-0 = <&hp_det>;
85
86		simple-audio-card,name = "realtek,rt5616-codec";
87		simple-audio-card,format = "i2s";
88		simple-audio-card,mclk-fs = <256>;
89
90		simple-audio-card,hp-det-gpios = <&gpio1 RK_PC4 GPIO_ACTIVE_LOW>;
91
92		simple-audio-card,widgets =
93			"Headphone", "Headphones",
94			"Microphone", "Microphone Jack";
95		simple-audio-card,routing =
96			"Headphones", "HPOL",
97			"Headphones", "HPOR",
98			"MIC1", "Microphone Jack",
99			"Microphone Jack", "micbias1";
100
101		simple-audio-card,cpu {
102			sound-dai = <&i2s0_8ch>;
103		};
104		simple-audio-card,codec {
105			sound-dai = <&rt5616>;
106		};
107	};
108
109	vcc12v_dcin: regulator-vcc12v-dcin {
110		compatible = "regulator-fixed";
111		regulator-name = "vcc12v_dcin";
112		regulator-always-on;
113		regulator-boot-on;
114		regulator-min-microvolt = <12000000>;
115		regulator-max-microvolt = <12000000>;
116	};
117
118	/* vcc5v0_sys powers peripherals */
119	vcc5v0_sys: regulator-vcc5v0-sys {
120		compatible = "regulator-fixed";
121		regulator-name = "vcc5v0_sys";
122		regulator-always-on;
123		regulator-boot-on;
124		regulator-min-microvolt = <5000000>;
125		regulator-max-microvolt = <5000000>;
126		vin-supply = <&vcc12v_dcin>;
127	};
128
129	/* vcc4v0_sys powers the RK806, RK860's */
130	vcc4v0_sys: regulator-vcc4v0-sys {
131		compatible = "regulator-fixed";
132		regulator-name = "vcc4v0_sys";
133		regulator-always-on;
134		regulator-boot-on;
135		regulator-min-microvolt = <4000000>;
136		regulator-max-microvolt = <4000000>;
137		vin-supply = <&vcc12v_dcin>;
138	};
139
140	vcc_1v1_nldo_s3: regulator-vcc-1v1-nldo-s3 {
141		compatible = "regulator-fixed";
142		regulator-name = "vcc-1v1-nldo-s3";
143		regulator-always-on;
144		regulator-boot-on;
145		regulator-min-microvolt = <1100000>;
146		regulator-max-microvolt = <1100000>;
147		vin-supply = <&vcc4v0_sys>;
148	};
149
150	vcc_3v3_pcie20: regulator-vcc3v3-pcie20 {
151		compatible = "regulator-fixed";
152		regulator-name = "vcc_3v3_pcie20";
153		regulator-always-on;
154		regulator-boot-on;
155		regulator-min-microvolt = <3300000>;
156		regulator-max-microvolt = <3300000>;
157		vin-supply = <&vcc_3v3_s3>;
158	};
159
160	vbus5v0_typec: regulator-vbus5v0-typec {
161		compatible = "regulator-fixed";
162		enable-active-high;
163		gpio = <&gpio1 RK_PD2 GPIO_ACTIVE_HIGH>;
164		pinctrl-names = "default";
165		pinctrl-0 = <&typec5v_pwren>;
166		regulator-always-on;
167		regulator-boot-on;
168		regulator-name = "vbus5v0_typec";
169		regulator-min-microvolt = <5000000>;
170		regulator-max-microvolt = <5000000>;
171		vin-supply = <&vcc5v0_sys>;
172	};
173
174	vbus5v0_usb: regulator-vbus5v0-usb {
175		compatible = "regulator-fixed";
176		enable-active-high;
177		gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_HIGH>;
178		pinctrl-names = "default";
179		pinctrl-0 = <&usb5v_pwren>;
180		regulator-always-on;
181		regulator-boot-on;
182		regulator-name = "vbus5v0_usb";
183		regulator-min-microvolt = <5000000>;
184		regulator-max-microvolt = <5000000>;
185		vin-supply = <&vcc5v0_sys>;
186	};
187
188	vcc3v3_pcie2x1l0: regulator-vcc3v3-pcie2x1l0 {
189		compatible = "regulator-fixed";
190		enable-active-high;
191		gpio = <&gpio4 RK_PC2 GPIO_ACTIVE_HIGH>;
192		pinctrl-names = "default";
193		pinctrl-0 = <&pcie_m2_1_pwren>;
194		regulator-name = "vcc3v3_pcie2x1l0";
195		regulator-min-microvolt = <3300000>;
196		regulator-max-microvolt = <3300000>;
197		vin-supply = <&vcc5v0_sys>;
198	};
199
200	vcc3v3_pcie30: regulator-vcc3v3-pcie30 {
201		compatible = "regulator-fixed";
202		enable-active-high;
203		gpios = <&gpio2 RK_PC5 GPIO_ACTIVE_HIGH>;
204		pinctrl-names = "default";
205		pinctrl-0 = <&pcie_m2_0_pwren>;
206		regulator-name = "vcc3v3_pcie30";
207		regulator-min-microvolt = <3300000>;
208		regulator-max-microvolt = <3300000>;
209		vin-supply = <&vcc5v0_sys>;
210	};
211
212	vcc3v3_sd_s0: regulator-vcc3v3-sd-s0 {
213		compatible = "regulator-fixed";
214		gpio = <&gpio4 RK_PA5 GPIO_ACTIVE_LOW>;
215		regulator-boot-on;
216		regulator-max-microvolt = <3300000>;
217		regulator-min-microvolt = <3300000>;
218		regulator-name = "vcc3v3_sd_s0";
219		vin-supply = <&vcc_3v3_s3>;
220	};
221};
222
223&combphy0_ps {
224	status = "okay";
225};
226
227&combphy1_ps {
228	status = "okay";
229};
230
231&combphy2_psu {
232	status = "okay";
233};
234
235&cpu_l0 {
236	cpu-supply = <&vdd_cpu_lit_s0>;
237};
238
239&cpu_l1 {
240	cpu-supply = <&vdd_cpu_lit_s0>;
241};
242
243&cpu_l2 {
244	cpu-supply = <&vdd_cpu_lit_s0>;
245};
246
247&cpu_l3 {
248	cpu-supply = <&vdd_cpu_lit_s0>;
249};
250
251&cpu_b0 {
252	cpu-supply = <&vdd_cpu_big0_s0>;
253};
254
255&cpu_b1 {
256	cpu-supply = <&vdd_cpu_big0_s0>;
257};
258
259&cpu_b2 {
260	cpu-supply = <&vdd_cpu_big1_s0>;
261};
262
263&cpu_b3 {
264	cpu-supply = <&vdd_cpu_big1_s0>;
265};
266
267&gpio0 {
268	gpio-line-names = /* GPIO0 A0-A7 */
269			  "", "", "", "",
270			  "", "", "", "",
271			  /* GPIO0 B0-B7 */
272			  "", "", "", "",
273			  "", "", "", "",
274			  /* GPIO0 C0-C7 */
275			  "", "", "", "",
276			  "HEADER_10", "HEADER_08", "HEADER_32", "",
277			  /* GPIO0 D0-D7 */
278			  "", "", "", "",
279			  "IR receiver [PWM3_IR_M0]", "", "", "";
280};
281
282&gpio1 {
283	gpio-line-names = /* GPIO1 A0-A7 */
284			  "HEADER_27", "HEADER_28", "", "",
285			  "", "", "", "HEADER_15",
286			  /* GPIO1 B0-B7 */
287			  "HEADER_26", "HEADER_21", "HEADER_19", "HEADER_23",
288			  "HEADER_24", "HEADER_22", "", "",
289			  /* GPIO1 C0-C7 */
290			  "", "", "", "",
291			  "", "", "", "",
292			  /* GPIO1 D0-D7 */
293			  "", "", "", "",
294			  "", "", "HEADER_05", "HEADER_03";
295};
296
297&gpio2 {
298	gpio-line-names = /* GPIO2 A0-A7 */
299			  "", "", "", "",
300			  "", "", "", "",
301			  /* GPIO2 B0-B7 */
302			  "", "", "", "",
303			  "", "", "", "",
304			  /* GPIO2 C0-C7 */
305			  "", "CSI1_11", "CSI1_12", "",
306			  "", "", "", "",
307			  /* GPIO2 D0-D7 */
308			  "", "", "", "",
309			  "", "", "", "";
310};
311
312&gpio3 {
313	gpio-line-names = /* GPIO3 A0-A7 */
314			  "HEADER_35", "HEADER_38", "HEADER_40", "HEADER_36",
315			  "HEADER_37", "", "DSI0_12", "",
316			  /* GPIO3 B0-B7 */
317			  "HEADER_33", "DSI0_10", "HEADER_07", "HEADER_16",
318			  "HEADER_18", "HEADER_29", "HEADER_31", "HEADER_12",
319			  /* GPIO3 C0-C7 */
320			  "DSI0_08", "DSI0_14", "HEADER_11", "HEADER_13",
321			  "", "", "", "",
322			  /* GPIO3 D0-D7 */
323			  "", "", "", "",
324			  "", "DSI1_10", "", "";
325};
326
327&gpio4 {
328	gpio-line-names = /* GPIO4 A0-A7 */
329			  "DSI1_08", "DSI1_14", "", "DSI1_12",
330			  "", "", "", "",
331			  /* GPIO4 B0-B7 */
332			  "", "", "", "",
333			  "", "", "", "",
334			  /* GPIO4 C0-C7 */
335			  "", "", "", "",
336			  "CSI0_11", "CSI0_12", "", "",
337			  /* GPIO4 D0-D7 */
338			  "", "", "", "",
339			  "", "", "", "";
340};
341
342&gpu {
343	mali-supply = <&vdd_gpu_s0>;
344	status = "okay";
345};
346
347&hdmi0 {
348	status = "okay";
349};
350
351&hdmi0_in {
352	hdmi0_in_vp0: endpoint {
353		remote-endpoint = <&vp0_out_hdmi0>;
354	};
355};
356
357&hdmi0_out {
358	hdmi0_out_con: endpoint {
359		remote-endpoint = <&hdmi0_con_in>;
360	};
361};
362
363&hdptxphy_hdmi0 {
364	status = "okay";
365};
366
367&i2c0 {
368	pinctrl-names = "default";
369	pinctrl-0 = <&i2c0m2_xfer>;
370	status = "okay";
371
372	vdd_cpu_big0_s0: regulator@42 {
373		compatible = "rockchip,rk8602";
374		reg = <0x42>;
375		fcs,suspend-voltage-selector = <1>;
376		regulator-name = "vdd_cpu_big0_s0";
377		regulator-always-on;
378		regulator-boot-on;
379		regulator-min-microvolt = <550000>;
380		regulator-max-microvolt = <1050000>;
381		regulator-ramp-delay = <2300>;
382		vin-supply = <&vcc4v0_sys>;
383
384		regulator-state-mem {
385			regulator-off-in-suspend;
386		};
387	};
388
389	vdd_cpu_big1_s0: regulator@43 {
390		compatible = "rockchip,rk8603", "rockchip,rk8602";
391		reg = <0x43>;
392		fcs,suspend-voltage-selector = <1>;
393		regulator-name = "vdd_cpu_big1_s0";
394		regulator-always-on;
395		regulator-boot-on;
396		regulator-min-microvolt = <550000>;
397		regulator-max-microvolt = <1050000>;
398		regulator-ramp-delay = <2300>;
399		vin-supply = <&vcc4v0_sys>;
400
401		regulator-state-mem {
402			regulator-off-in-suspend;
403		};
404	};
405};
406
407&i2c2 {
408	status = "okay";
409
410	vdd_npu_s0: regulator@42 {
411		compatible = "rockchip,rk8602";
412		reg = <0x42>;
413		fcs,suspend-voltage-selector = <1>;
414		regulator-name = "vdd_npu_s0";
415		regulator-always-on;
416		regulator-boot-on;
417		regulator-min-microvolt = <550000>;
418		regulator-max-microvolt = <950000>;
419		regulator-ramp-delay = <2300>;
420		vin-supply = <&vcc4v0_sys>;
421
422		regulator-state-mem {
423			regulator-off-in-suspend;
424		};
425	};
426};
427
428&i2c6 {
429	clock-frequency = <200000>;
430	status = "okay";
431
432	fusb302: typec-portc@22 {
433		compatible = "fcs,fusb302";
434		reg = <0x22>;
435		interrupt-parent = <&gpio0>;
436		interrupts = <RK_PD3 IRQ_TYPE_LEVEL_LOW>;
437		pinctrl-0 = <&usbc0_int>;
438		pinctrl-names = "default";
439		vbus-supply = <&vbus5v0_typec>;
440
441		connector {
442			compatible = "usb-c-connector";
443			data-role = "dual";
444			label = "USB-C";
445			power-role = "source";
446			source-pdos = <PDO_FIXED(5000, 2000, PDO_FIXED_USB_COMM)>;
447
448			ports {
449				#address-cells = <1>;
450				#size-cells = <0>;
451
452				port@0 {
453					reg = <0>;
454					usbc0_hs: endpoint {
455						remote-endpoint = <&usb_host0_xhci_drd_sw>;
456					};
457				};
458
459				port@1 {
460					reg = <1>;
461					usbc0_ss: endpoint {
462						remote-endpoint = <&usbdp_phy0_typec_ss>;
463					};
464				};
465
466				port@2 {
467					reg = <2>;
468					usbc0_sbu: endpoint {
469						remote-endpoint = <&usbdp_phy0_typec_sbu>;
470					};
471				};
472			};
473		};
474	};
475
476	hym8563: rtc@51 {
477		compatible = "haoyu,hym8563";
478		reg = <0x51>;
479		#clock-cells = <0>;
480		clock-output-names = "hym8563";
481		pinctrl-names = "default";
482		pinctrl-0 = <&hym8563_int>;
483		interrupt-parent = <&gpio0>;
484		interrupts = <RK_PB0 IRQ_TYPE_LEVEL_LOW>;
485		wakeup-source;
486	};
487};
488
489&i2c7 {
490	clock-frequency = <200000>;
491	status = "okay";
492
493	rt5616: codec@1b {
494		compatible = "realtek,rt5616";
495		reg = <0x1b>;
496		clocks = <&cru I2S0_8CH_MCLKOUT>;
497		clock-names = "mclk";
498		#sound-dai-cells = <0>;
499		assigned-clocks = <&cru I2S0_8CH_MCLKOUT>;
500		assigned-clock-rates = <12288000>;
501
502		port {
503			rt5616_p0_0: endpoint {
504				remote-endpoint = <&i2s0_8ch_p0_0>;
505			};
506		};
507	};
508
509	/* connected with MIPI-CSI1 */
510};
511
512&i2c8 {
513	pinctrl-0 = <&i2c8m2_xfer>;
514};
515
516&i2s0_8ch {
517	pinctrl-names = "default";
518	pinctrl-0 = <&i2s0_lrck
519		     &i2s0_mclk
520		     &i2s0_sclk
521		     &i2s0_sdi0
522		     &i2s0_sdo0>;
523	status = "okay";
524
525	i2s0_8ch_p0: port {
526		i2s0_8ch_p0_0: endpoint {
527			dai-format = "i2s";
528			mclk-fs = <256>;
529			remote-endpoint = <&rt5616_p0_0>;
530		};
531	};
532};
533
534&pcie2x1l0 {
535	reset-gpios = <&gpio4 RK_PB3 GPIO_ACTIVE_HIGH>;
536	vpcie3v3-supply = <&vcc_3v3_pcie20>;
537	pinctrl-names = "default";
538	pinctrl-0 = <&pcie2_0_rst>;
539	status = "okay";
540};
541
542&pcie2x1l1 {
543	reset-gpios = <&gpio4 RK_PA2 GPIO_ACTIVE_HIGH>;
544	vpcie3v3-supply = <&vcc3v3_pcie2x1l0>;
545	pinctrl-names = "default";
546	pinctrl-0 = <&pcie2_1_rst>;
547	status = "okay";
548};
549
550&pcie2x1l2 {
551	reset-gpios = <&gpio4 RK_PA4 GPIO_ACTIVE_HIGH>;
552	vpcie3v3-supply = <&vcc_3v3_pcie20>;
553	pinctrl-names = "default";
554	pinctrl-0 = <&pcie2_2_rst>;
555	status = "okay";
556};
557
558&pcie30phy {
559	status = "okay";
560};
561
562&pcie3x4 {
563	reset-gpios = <&gpio4 RK_PB6 GPIO_ACTIVE_HIGH>;
564	vpcie3v3-supply = <&vcc3v3_pcie30>;
565	status = "okay";
566};
567
568&pinctrl {
569	gpio-leds {
570		sys_led_pin: sys-led-pin {
571			rockchip,pins = <2 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>;
572		};
573
574		usr_led_pin: usr-led-pin {
575			rockchip,pins = <2 RK_PC0 RK_FUNC_GPIO &pcfg_pull_none>;
576		};
577	};
578
579	headphone {
580		hp_det: hp-det {
581			rockchip,pins = <1 RK_PC4 RK_FUNC_GPIO &pcfg_pull_none>;
582		};
583	};
584
585	hym8563 {
586		hym8563_int: hym8563-int {
587			rockchip,pins = <0 RK_PB0 RK_FUNC_GPIO &pcfg_pull_up>;
588		};
589	};
590
591	ir-receiver {
592		ir_receiver_pin: ir-receiver-pin {
593			rockchip,pins = <0 RK_PD4 RK_FUNC_GPIO &pcfg_pull_none>;
594		};
595	};
596
597	pcie {
598		pcie2_0_rst: pcie2-0-rst {
599			rockchip,pins = <4 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>;
600		};
601
602		pcie2_1_rst: pcie2-1-rst {
603			rockchip,pins = <4 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
604		};
605
606		pcie2_2_rst: pcie2-2-rst {
607			rockchip,pins = <4 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>;
608		};
609
610		pcie_m2_0_pwren: pcie-m20-pwren {
611			rockchip,pins = <2 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>;
612		};
613
614		pcie_m2_1_pwren: pcie-m21-pwren {
615			rockchip,pins = <4 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>;
616		};
617	};
618
619	usb {
620		typec5v_pwren: typec5v-pwren {
621			rockchip,pins = <1 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>;
622		};
623
624		usb5v_pwren: usb5v_pwren {
625			rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>;
626		};
627
628		usbc0_int: usbc0-int {
629			rockchip,pins = <0 RK_PD3 RK_FUNC_GPIO &pcfg_pull_up>;
630		};
631	};
632};
633
634&pwm1 {
635	pinctrl-0 = <&pwm1m1_pins>;
636	status = "okay";
637};
638
639&saradc {
640	vref-supply = <&avcc_1v8_s0>;
641	status = "okay";
642};
643
644&sdhci {
645	bus-width = <8>;
646	no-sdio;
647	no-sd;
648	non-removable;
649	max-frequency = <200000000>;
650	mmc-hs400-1_8v;
651	mmc-hs400-enhanced-strobe;
652	status = "okay";
653};
654
655&sdmmc {
656	bus-width = <4>;
657	cap-mmc-highspeed;
658	cap-sd-highspeed;
659	cd-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_LOW>;
660	disable-wp;
661	no-mmc;
662	no-sdio;
663	sd-uhs-sdr104;
664	vmmc-supply = <&vcc3v3_sd_s0>;
665	vqmmc-supply = <&vccio_sd_s0>;
666	status = "okay";
667};
668
669/* optional on non-LTS, populated on LTS version */
670&sfc {
671	pinctrl-names = "default";
672	pinctrl-0 = <&fspim1_pins>;
673	status = "okay";
674
675	flash@0 {
676		compatible = "jedec,spi-nor";
677		reg = <0>;
678		spi-max-frequency = <104000000>;
679		spi-rx-bus-width = <4>;
680		spi-tx-bus-width = <1>;
681	};
682};
683
684&spi2 {
685	status = "okay";
686	assigned-clocks = <&cru CLK_SPI2>;
687	assigned-clock-rates = <200000000>;
688	pinctrl-names = "default";
689	pinctrl-0 = <&spi2m2_cs0 &spi2m2_pins>;
690	num-cs = <1>;
691
692	pmic@0 {
693		compatible = "rockchip,rk806";
694		spi-max-frequency = <1000000>;
695		reg = <0x0>;
696
697		interrupt-parent = <&gpio0>;
698		interrupts = <7 IRQ_TYPE_LEVEL_LOW>;
699
700		pinctrl-names = "default";
701		pinctrl-0 = <&pmic_pins>, <&rk806_dvs1_null>,
702			    <&rk806_dvs2_null>, <&rk806_dvs3_null>;
703
704		system-power-controller;
705
706		vcc1-supply = <&vcc4v0_sys>;
707		vcc2-supply = <&vcc4v0_sys>;
708		vcc3-supply = <&vcc4v0_sys>;
709		vcc4-supply = <&vcc4v0_sys>;
710		vcc5-supply = <&vcc4v0_sys>;
711		vcc6-supply = <&vcc4v0_sys>;
712		vcc7-supply = <&vcc4v0_sys>;
713		vcc8-supply = <&vcc4v0_sys>;
714		vcc9-supply = <&vcc4v0_sys>;
715		vcc10-supply = <&vcc4v0_sys>;
716		vcc11-supply = <&vcc_2v0_pldo_s3>;
717		vcc12-supply = <&vcc4v0_sys>;
718		vcc13-supply = <&vcc_1v1_nldo_s3>;
719		vcc14-supply = <&vcc_1v1_nldo_s3>;
720		vcca-supply = <&vcc4v0_sys>;
721
722		gpio-controller;
723		#gpio-cells = <2>;
724
725		rk806_dvs1_null: dvs1-null-pins {
726			pins = "gpio_pwrctrl1";
727			function = "pin_fun0";
728		};
729
730		rk806_dvs2_null: dvs2-null-pins {
731			pins = "gpio_pwrctrl2";
732			function = "pin_fun0";
733		};
734
735		rk806_dvs3_null: dvs3-null-pins {
736			pins = "gpio_pwrctrl3";
737			function = "pin_fun0";
738		};
739
740		regulators {
741			vdd_gpu_s0: vdd_gpu_mem_s0: dcdc-reg1 {
742				regulator-boot-on;
743				regulator-min-microvolt = <550000>;
744				regulator-max-microvolt = <950000>;
745				regulator-ramp-delay = <12500>;
746				regulator-name = "vdd_gpu_s0";
747				regulator-enable-ramp-delay = <400>;
748
749				regulator-state-mem {
750					regulator-off-in-suspend;
751				};
752			};
753
754			vdd_cpu_lit_s0: vdd_cpu_lit_mem_s0: dcdc-reg2 {
755				regulator-always-on;
756				regulator-boot-on;
757				regulator-min-microvolt = <550000>;
758				regulator-max-microvolt = <950000>;
759				regulator-ramp-delay = <12500>;
760				regulator-name = "vdd_cpu_lit_s0";
761
762				regulator-state-mem {
763					regulator-off-in-suspend;
764				};
765			};
766
767			vdd_log_s0: dcdc-reg3 {
768				regulator-always-on;
769				regulator-boot-on;
770				regulator-min-microvolt = <675000>;
771				regulator-max-microvolt = <750000>;
772				regulator-ramp-delay = <12500>;
773				regulator-name = "vdd_log_s0";
774
775				regulator-state-mem {
776					regulator-off-in-suspend;
777					regulator-suspend-microvolt = <750000>;
778				};
779			};
780
781			vdd_vdenc_s0: vdd_vdenc_mem_s0: dcdc-reg4 {
782				regulator-always-on;
783				regulator-boot-on;
784				regulator-min-microvolt = <550000>;
785				regulator-max-microvolt = <950000>;
786				regulator-ramp-delay = <12500>;
787				regulator-name = "vdd_vdenc_s0";
788
789				regulator-state-mem {
790					regulator-off-in-suspend;
791				};
792			};
793
794			vdd_ddr_s0: dcdc-reg5 {
795				regulator-always-on;
796				regulator-boot-on;
797				regulator-min-microvolt = <675000>;
798				regulator-max-microvolt = <900000>;
799				regulator-ramp-delay = <12500>;
800				regulator-name = "vdd_ddr_s0";
801
802				regulator-state-mem {
803					regulator-off-in-suspend;
804					regulator-suspend-microvolt = <850000>;
805				};
806			};
807
808			vdd2_ddr_s3: dcdc-reg6 {
809				regulator-always-on;
810				regulator-boot-on;
811				regulator-name = "vdd2_ddr_s3";
812
813				regulator-state-mem {
814					regulator-on-in-suspend;
815				};
816			};
817
818			vcc_2v0_pldo_s3: dcdc-reg7 {
819				regulator-always-on;
820				regulator-boot-on;
821				regulator-min-microvolt = <2000000>;
822				regulator-max-microvolt = <2000000>;
823				regulator-ramp-delay = <12500>;
824				regulator-name = "vdd_2v0_pldo_s3";
825
826				regulator-state-mem {
827					regulator-on-in-suspend;
828					regulator-suspend-microvolt = <2000000>;
829				};
830			};
831
832			vcc_3v3_s3: dcdc-reg8 {
833				regulator-always-on;
834				regulator-boot-on;
835				regulator-min-microvolt = <3300000>;
836				regulator-max-microvolt = <3300000>;
837				regulator-name = "vcc_3v3_s3";
838
839				regulator-state-mem {
840					regulator-on-in-suspend;
841					regulator-suspend-microvolt = <3300000>;
842				};
843			};
844
845			vddq_ddr_s0: dcdc-reg9 {
846				regulator-always-on;
847				regulator-boot-on;
848				regulator-name = "vddq_ddr_s0";
849
850				regulator-state-mem {
851					regulator-off-in-suspend;
852				};
853			};
854
855			vcc_1v8_s3: dcdc-reg10 {
856				regulator-always-on;
857				regulator-boot-on;
858				regulator-min-microvolt = <1800000>;
859				regulator-max-microvolt = <1800000>;
860				regulator-name = "vcc_1v8_s3";
861
862				regulator-state-mem {
863					regulator-on-in-suspend;
864					regulator-suspend-microvolt = <1800000>;
865				};
866			};
867
868			avcc_1v8_s0: pldo-reg1 {
869				regulator-always-on;
870				regulator-boot-on;
871				regulator-min-microvolt = <1800000>;
872				regulator-max-microvolt = <1800000>;
873				regulator-name = "avcc_1v8_s0";
874
875				regulator-state-mem {
876					regulator-off-in-suspend;
877				};
878			};
879
880			vcc_1v8_s0: pldo-reg2 {
881				regulator-always-on;
882				regulator-boot-on;
883				regulator-min-microvolt = <1800000>;
884				regulator-max-microvolt = <1800000>;
885				regulator-name = "vcc_1v8_s0";
886
887				regulator-state-mem {
888					regulator-off-in-suspend;
889					regulator-suspend-microvolt = <1800000>;
890				};
891			};
892
893			avdd_1v2_s0: pldo-reg3 {
894				regulator-always-on;
895				regulator-boot-on;
896				regulator-min-microvolt = <1200000>;
897				regulator-max-microvolt = <1200000>;
898				regulator-name = "avdd_1v2_s0";
899
900				regulator-state-mem {
901					regulator-off-in-suspend;
902				};
903			};
904
905			vcc_3v3_s0: pldo-reg4 {
906				regulator-always-on;
907				regulator-boot-on;
908				regulator-min-microvolt = <3300000>;
909				regulator-max-microvolt = <3300000>;
910				regulator-ramp-delay = <12500>;
911				regulator-name = "vcc_3v3_s0";
912
913				regulator-state-mem {
914					regulator-off-in-suspend;
915				};
916			};
917
918			vccio_sd_s0: pldo-reg5 {
919				regulator-always-on;
920				regulator-boot-on;
921				regulator-min-microvolt = <1800000>;
922				regulator-max-microvolt = <3300000>;
923				regulator-ramp-delay = <12500>;
924				regulator-name = "vccio_sd_s0";
925
926				regulator-state-mem {
927					regulator-off-in-suspend;
928				};
929			};
930
931			pldo6_s3: pldo-reg6 {
932				regulator-always-on;
933				regulator-boot-on;
934				regulator-min-microvolt = <1800000>;
935				regulator-max-microvolt = <1800000>;
936				regulator-name = "pldo6_s3";
937
938				regulator-state-mem {
939					regulator-on-in-suspend;
940					regulator-suspend-microvolt = <1800000>;
941				};
942			};
943
944			vdd_0v75_s3: nldo-reg1 {
945				regulator-always-on;
946				regulator-boot-on;
947				regulator-min-microvolt = <750000>;
948				regulator-max-microvolt = <750000>;
949				regulator-name = "vdd_0v75_s3";
950
951				regulator-state-mem {
952					regulator-on-in-suspend;
953					regulator-suspend-microvolt = <750000>;
954				};
955			};
956
957			vdd_ddr_pll_s0: nldo-reg2 {
958				regulator-always-on;
959				regulator-boot-on;
960				regulator-min-microvolt = <850000>;
961				regulator-max-microvolt = <850000>;
962				regulator-name = "vdd_ddr_pll_s0";
963
964				regulator-state-mem {
965					regulator-off-in-suspend;
966					regulator-suspend-microvolt = <850000>;
967				};
968			};
969
970			avdd_0v75_s0: nldo-reg3 {
971				regulator-always-on;
972				regulator-boot-on;
973				regulator-min-microvolt = <750000>;
974				regulator-max-microvolt = <750000>;
975				regulator-name = "avdd_0v75_s0";
976
977				regulator-state-mem {
978					regulator-off-in-suspend;
979				};
980			};
981
982			vdd_0v85_s0: nldo-reg4 {
983				regulator-always-on;
984				regulator-boot-on;
985				regulator-min-microvolt = <850000>;
986				regulator-max-microvolt = <850000>;
987				regulator-name = "vdd_0v85_s0";
988
989				regulator-state-mem {
990					regulator-off-in-suspend;
991				};
992			};
993
994			vdd_0v75_s0: nldo-reg5 {
995				regulator-always-on;
996				regulator-boot-on;
997				regulator-min-microvolt = <750000>;
998				regulator-max-microvolt = <750000>;
999				regulator-name = "vdd_0v75_s0";
1000
1001				regulator-state-mem {
1002					regulator-off-in-suspend;
1003				};
1004			};
1005		};
1006	};
1007};
1008
1009&tsadc {
1010	status = "okay";
1011};
1012
1013&uart2 {
1014	pinctrl-0 = <&uart2m0_xfer>;
1015	status = "okay";
1016};
1017
1018&u2phy0 {
1019	status = "okay";
1020};
1021
1022&u2phy0_otg {
1023	status = "okay";
1024};
1025
1026&u2phy1 {
1027	status = "okay";
1028};
1029
1030&u2phy1_otg {
1031	status = "okay";
1032};
1033
1034&u2phy2_host {
1035	status = "okay";
1036};
1037
1038&u2phy3_host {
1039	status = "okay";
1040};
1041
1042&u2phy2 {
1043	status = "okay";
1044};
1045
1046&u2phy3 {
1047	status = "okay";
1048};
1049
1050&usbdp_phy0 {
1051	mode-switch;
1052	orientation-switch;
1053	sbu1-dc-gpios = <&gpio4 RK_PA6 GPIO_ACTIVE_HIGH>;
1054	sbu2-dc-gpios = <&gpio4 RK_PA7 GPIO_ACTIVE_HIGH>;
1055	status = "okay";
1056
1057	port {
1058		#address-cells = <1>;
1059		#size-cells = <0>;
1060
1061		usbdp_phy0_typec_ss: endpoint@0 {
1062			reg = <0>;
1063			remote-endpoint = <&usbc0_ss>;
1064		};
1065
1066		usbdp_phy0_typec_sbu: endpoint@1 {
1067			reg = <1>;
1068			remote-endpoint = <&usbc0_sbu>;
1069		};
1070	};
1071};
1072
1073&usbdp_phy1 {
1074	phy-supply = <&vbus5v0_usb>;
1075	status = "okay";
1076};
1077
1078&usb_host0_ehci {
1079	status = "okay";
1080};
1081
1082&usb_host0_ohci {
1083	status = "okay";
1084};
1085
1086&usb_host0_xhci {
1087	dr_mode = "host";
1088	status = "okay";
1089	usb-role-switch;
1090
1091	port {
1092		usb_host0_xhci_drd_sw: endpoint {
1093			remote-endpoint = <&usbc0_hs>;
1094		};
1095	};
1096};
1097
1098&usb_host1_xhci {
1099	dr_mode = "host";
1100	status = "okay";
1101};
1102
1103&usb_host1_ehci {
1104	status = "okay";
1105};
1106
1107&usb_host1_ohci {
1108	status = "okay";
1109};
1110
1111&vop_mmu {
1112	status = "okay";
1113};
1114
1115&vop {
1116	status = "okay";
1117};
1118
1119&vp0 {
1120	vp0_out_hdmi0: endpoint@ROCKCHIP_VOP2_EP_HDMI0 {
1121		reg = <ROCKCHIP_VOP2_EP_HDMI0>;
1122		remote-endpoint = <&hdmi0_in_vp0>;
1123	};
1124};
1125