xref: /linux/arch/arm64/boot/dts/rockchip/rk3576-armsom-sige5.dts (revision 26bda0dff9ca74ae071643e0176f248d72f43580)
1// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2/*
3 * Copyright (c) 2024 Rockchip Electronics Co., Ltd.
4 *
5 */
6
7/dts-v1/;
8
9#include <dt-bindings/gpio/gpio.h>
10#include <dt-bindings/leds/common.h>
11#include <dt-bindings/pinctrl/rockchip.h>
12#include <dt-bindings/pwm/pwm.h>
13#include <dt-bindings/usb/pd.h>
14#include "rk3576.dtsi"
15
16/ {
17	model = "ArmSoM Sige5";
18	compatible = "armsom,sige5", "rockchip,rk3576";
19
20	aliases {
21		ethernet0 = &gmac0;
22		ethernet1 = &gmac1;
23	};
24
25	chosen {
26		stdout-path = "serial0:1500000n8";
27	};
28
29	leds: leds {
30		compatible = "gpio-leds";
31
32		green_led: green-led {
33			color = <LED_COLOR_ID_GREEN>;
34			function = LED_FUNCTION_HEARTBEAT;
35			gpios = <&gpio4 RK_PB2 GPIO_ACTIVE_HIGH>;
36			linux,default-trigger = "heartbeat";
37		};
38
39		red_led: red-led {
40			color = <LED_COLOR_ID_RED>;
41			function = LED_FUNCTION_STATUS;
42			gpios = <&gpio4 RK_PB1 GPIO_ACTIVE_HIGH>;
43			linux,default-trigger = "default-on";
44		};
45	};
46
47	vcc_12v0_dcin: regulator-vcc-12v0-dcin {
48		compatible = "regulator-fixed";
49		regulator-name = "vcc_12v0_dcin";
50		regulator-always-on;
51		regulator-boot-on;
52		regulator-min-microvolt = <12000000>;
53		regulator-max-microvolt = <12000000>;
54	};
55
56	vcc_1v1_nldo_s3: regulator-vcc-1v1-nldo-s3 {
57		compatible = "regulator-fixed";
58		regulator-name = "vcc_1v1_nldo_s3";
59		regulator-boot-on;
60		regulator-always-on;
61		regulator-min-microvolt = <1100000>;
62		regulator-max-microvolt = <1100000>;
63		vin-supply = <&vcc_5v0_sys>;
64	};
65
66	vcc_1v2_ufs_vccq_s0: regulator-vcc-1v2-ufs-vccq-s0 {
67		compatible = "regulator-fixed";
68		regulator-name = "vcc_1v2_ufs_vccq_s0";
69		regulator-boot-on;
70		regulator-always-on;
71		regulator-min-microvolt = <1200000>;
72		regulator-max-microvolt = <1200000>;
73		vin-supply = <&vcc_5v0_sys>;
74	};
75
76	vcc_1v8_s0: regulator-vcc-1v8-s0 {
77		compatible = "regulator-fixed";
78		regulator-name = "vcc_1v8_s0";
79		regulator-boot-on;
80		regulator-always-on;
81		regulator-min-microvolt = <1800000>;
82		regulator-max-microvolt = <1800000>;
83		vin-supply = <&vcc_1v8_s3>;
84	};
85
86	vcc_1v8_ufs_vccq2_s0: regulator-vcc-1v8-ufs-vccq2-s0 {
87		compatible = "regulator-fixed";
88		regulator-name = "vcc_1v8_ufs_vccq2_s0";
89		regulator-boot-on;
90		regulator-always-on;
91		regulator-min-microvolt = <1800000>;
92		regulator-max-microvolt = <1800000>;
93		vin-supply = <&vcc_1v8_s3>;
94	};
95
96	vcc_2v0_pldo_s3: regulator-vcc-2v0-pldo-s3 {
97		compatible = "regulator-fixed";
98		regulator-name = "vcc_2v0_pldo_s3";
99		regulator-boot-on;
100		regulator-always-on;
101		regulator-min-microvolt = <2000000>;
102		regulator-max-microvolt = <2000000>;
103		vin-supply = <&vcc_5v0_sys>;
104	};
105
106	vcc_3v3_pcie: regulator-vcc-3v3-pcie {
107		compatible = "regulator-fixed";
108		regulator-name = "vcc_3v3_pcie";
109		regulator-min-microvolt = <3300000>;
110		regulator-max-microvolt = <3300000>;
111		enable-active-high;
112		gpio = <&gpio3 RK_PD6 GPIO_ACTIVE_HIGH>;
113		startup-delay-us = <5000>;
114		vin-supply = <&vcc_5v0_sys>;
115	};
116
117	vcc_3v3_rtc_s5: regulator-vcc-3v3-rtc-s5 {
118		compatible = "regulator-fixed";
119		regulator-name = "vcc_3v3_rtc_s5";
120		regulator-boot-on;
121		regulator-always-on;
122		regulator-min-microvolt = <3300000>;
123		regulator-max-microvolt = <3300000>;
124		vin-supply = <&vcc_5v0_sys>;
125	};
126
127	vcc_3v3_s0: regulator-vcc-3v3-s0 {
128		compatible = "regulator-fixed";
129		regulator-name = "vcc_3v3_s0";
130		regulator-boot-on;
131		regulator-always-on;
132		regulator-min-microvolt = <3300000>;
133		regulator-max-microvolt = <3300000>;
134		vin-supply = <&vcc_3v3_s3>;
135	};
136
137	vcc_5v0_sys: regulator-vcc-5v0-sys {
138		compatible = "regulator-fixed";
139		regulator-name = "vcc_5v0_sys";
140		regulator-always-on;
141		regulator-boot-on;
142		regulator-min-microvolt = <5000000>;
143		regulator-max-microvolt = <5000000>;
144		vin-supply = <&vcc_12v0_dcin>;
145	};
146
147	vcc_5v0_device: regulator-vcc-5v0-device {
148		compatible = "regulator-fixed";
149		regulator-name = "vcc_5v0_device";
150		regulator-always-on;
151		regulator-boot-on;
152		regulator-min-microvolt = <5000000>;
153		regulator-max-microvolt = <5000000>;
154		vin-supply = <&vcc_12v0_dcin>;
155	};
156
157	vcc_3v3_ufs_s0: regulator-vcc-ufs-s0 {
158		compatible = "regulator-fixed";
159		regulator-name = "vcc_3v3_ufs_s0";
160		regulator-boot-on;
161		regulator-always-on;
162		regulator-min-microvolt = <3300000>;
163		regulator-max-microvolt = <3300000>;
164		vin-supply = <&vcc_5v0_sys>;
165	};
166};
167
168&cpu_l0 {
169	cpu-supply = <&vdd_cpu_lit_s0>;
170};
171
172&gmac0 {
173	phy-mode = "rgmii-id";
174	clock_in_out = "output";
175
176	snps,reset-gpio = <&gpio2 RK_PB5 GPIO_ACTIVE_LOW>;
177	snps,reset-active-low;
178	snps,reset-delays-us = <0 20000 100000>;
179
180	pinctrl-names = "default";
181	pinctrl-0 = <&eth0m0_miim
182		     &eth0m0_tx_bus2
183		     &eth0m0_rx_bus2
184		     &eth0m0_rgmii_clk
185		     &eth0m0_rgmii_bus
186		     &ethm0_clk0_25m_out>;
187
188	phy-handle = <&rgmii_phy0>;
189	status = "okay";
190};
191
192&gmac1 {
193	phy-mode = "rgmii-id";
194	clock_in_out = "output";
195
196	snps,reset-gpio = <&gpio3 RK_PA3 GPIO_ACTIVE_LOW>;
197	snps,reset-active-low;
198	snps,reset-delays-us = <0 20000 100000>;
199
200	pinctrl-names = "default";
201	pinctrl-0 = <&eth1m0_miim
202		     &eth1m0_tx_bus2
203		     &eth1m0_rx_bus2
204		     &eth1m0_rgmii_clk
205		     &eth1m0_rgmii_bus
206		     &ethm0_clk1_25m_out>;
207
208	phy-handle = <&rgmii_phy1>;
209	status = "okay";
210};
211
212&gpu {
213	mali-supply = <&vdd_gpu_s0>;
214	status = "okay";
215};
216
217&i2c1 {
218	status = "okay";
219
220	pmic@23 {
221		compatible = "rockchip,rk806";
222		reg = <0x23>;
223
224		interrupt-parent = <&gpio0>;
225		interrupts = <6 IRQ_TYPE_LEVEL_LOW>;
226
227		pinctrl-names = "default";
228		pinctrl-0 = <&pmic_pins>, <&rk806_dvs1_null>,
229			    <&rk806_dvs2_null>, <&rk806_dvs3_null>;
230
231		system-power-controller;
232
233		vcc1-supply = <&vcc_5v0_sys>;
234		vcc2-supply = <&vcc_5v0_sys>;
235		vcc3-supply = <&vcc_5v0_sys>;
236		vcc4-supply = <&vcc_5v0_sys>;
237		vcc5-supply = <&vcc_5v0_sys>;
238		vcc6-supply = <&vcc_5v0_sys>;
239		vcc7-supply = <&vcc_5v0_sys>;
240		vcc8-supply = <&vcc_5v0_sys>;
241		vcc9-supply = <&vcc_5v0_sys>;
242		vcc10-supply = <&vcc_5v0_sys>;
243		vcc11-supply = <&vcc_2v0_pldo_s3>;
244		vcc12-supply = <&vcc_5v0_sys>;
245		vcc13-supply = <&vcc_1v1_nldo_s3>;
246		vcc14-supply = <&vcc_1v1_nldo_s3>;
247		vcca-supply = <&vcc_5v0_sys>;
248
249		gpio-controller;
250		#gpio-cells = <2>;
251
252		rk806_dvs1_null: dvs1-null-pins {
253			pins = "gpio_pwrctrl1";
254			function = "pin_fun0";
255		};
256
257		rk806_dvs2_null: dvs2-null-pins {
258			pins = "gpio_pwrctrl2";
259			function = "pin_fun0";
260		};
261
262		rk806_dvs3_null: dvs3-null-pins {
263			pins = "gpio_pwrctrl3";
264			function = "pin_fun0";
265		};
266
267		rk806_dvs1_slp: dvs1-slp-pins {
268			pins = "gpio_pwrctrl1";
269			function = "pin_fun1";
270		};
271
272		rk806_dvs1_pwrdn: dvs1-pwrdn-pins {
273			pins = "gpio_pwrctrl1";
274			function = "pin_fun2";
275		};
276
277		rk806_dvs1_rst: dvs1-rst-pins {
278			pins = "gpio_pwrctrl1";
279			function = "pin_fun3";
280		};
281
282		rk806_dvs2_slp: dvs2-slp-pins {
283			pins = "gpio_pwrctrl2";
284			function = "pin_fun1";
285		};
286
287		rk806_dvs2_pwrdn: dvs2-pwrdn-pins {
288			pins = "gpio_pwrctrl2";
289			function = "pin_fun2";
290		};
291
292		rk806_dvs2_rst: dvs2-rst-pins {
293			pins = "gpio_pwrctrl2";
294			function = "pin_fun3";
295		};
296
297		rk806_dvs2_dvs: dvs2-dvs-pins {
298			pins = "gpio_pwrctrl2";
299			function = "pin_fun4";
300		};
301
302		rk806_dvs2_gpio: dvs2-gpio-pins {
303			pins = "gpio_pwrctrl2";
304			function = "pin_fun5";
305		};
306
307		rk806_dvs3_slp: dvs3-slp-pins {
308			pins = "gpio_pwrctrl3";
309			function = "pin_fun1";
310		};
311
312		rk806_dvs3_pwrdn: dvs3-pwrdn-pins {
313			pins = "gpio_pwrctrl3";
314			function = "pin_fun2";
315		};
316
317		rk806_dvs3_rst: dvs3-rst-pins {
318			pins = "gpio_pwrctrl3";
319			function = "pin_fun3";
320		};
321
322		rk806_dvs3_dvs: dvs3-dvs-pins {
323			pins = "gpio_pwrctrl3";
324			function = "pin_fun4";
325		};
326
327		rk806_dvs3_gpio: dvs3-gpio-pins {
328			pins = "gpio_pwrctrl3";
329			function = "pin_fun5";
330		};
331
332		regulators {
333			vdd_cpu_big_s0: dcdc-reg1 {
334				regulator-always-on;
335				regulator-boot-on;
336				regulator-min-microvolt = <550000>;
337				regulator-max-microvolt = <950000>;
338				regulator-ramp-delay = <12500>;
339				regulator-name = "vdd_cpu_big_s0";
340				regulator-enable-ramp-delay = <400>;
341				regulator-state-mem {
342					regulator-off-in-suspend;
343				};
344			};
345
346			vdd_npu_s0: dcdc-reg2 {
347				regulator-boot-on;
348				regulator-min-microvolt = <550000>;
349				regulator-max-microvolt = <950000>;
350				regulator-ramp-delay = <12500>;
351				regulator-name = "vdd_npu_s0";
352				regulator-enable-ramp-delay = <400>;
353				regulator-state-mem {
354					regulator-off-in-suspend;
355				};
356			};
357
358			vdd_cpu_lit_s0: dcdc-reg3 {
359				regulator-always-on;
360				regulator-boot-on;
361				regulator-min-microvolt = <550000>;
362				regulator-max-microvolt = <950000>;
363				regulator-ramp-delay = <12500>;
364				regulator-name = "vdd_cpu_lit_s0";
365				regulator-state-mem {
366					regulator-off-in-suspend;
367					regulator-suspend-microvolt = <750000>;
368				};
369			};
370
371			vcc_3v3_s3: dcdc-reg4 {
372				regulator-always-on;
373				regulator-boot-on;
374				regulator-min-microvolt = <3300000>;
375				regulator-max-microvolt = <3300000>;
376				regulator-name = "vcc_3v3_s3";
377				regulator-state-mem {
378					regulator-on-in-suspend;
379					regulator-suspend-microvolt = <3300000>;
380				};
381			};
382
383			vdd_gpu_s0: dcdc-reg5 {
384				regulator-boot-on;
385				regulator-min-microvolt = <550000>;
386				regulator-max-microvolt = <900000>;
387				regulator-ramp-delay = <12500>;
388				regulator-name = "vdd_gpu_s0";
389				regulator-enable-ramp-delay = <400>;
390				regulator-state-mem {
391					regulator-off-in-suspend;
392					regulator-suspend-microvolt = <850000>;
393				};
394			};
395
396			vddq_ddr_s0: dcdc-reg6 {
397				regulator-always-on;
398				regulator-boot-on;
399				regulator-name = "vddq_ddr_s0";
400				regulator-state-mem {
401					regulator-off-in-suspend;
402				};
403			};
404
405			vdd_logic_s0: dcdc-reg7 {
406				regulator-always-on;
407				regulator-boot-on;
408				regulator-min-microvolt = <550000>;
409				regulator-max-microvolt = <800000>;
410				regulator-name = "vdd_logic_s0";
411				regulator-state-mem {
412					regulator-off-in-suspend;
413				};
414			};
415
416			vcc_1v8_s3: dcdc-reg8 {
417				regulator-always-on;
418				regulator-boot-on;
419				regulator-min-microvolt = <1800000>;
420				regulator-max-microvolt = <1800000>;
421				regulator-name = "vcc_1v8_s3";
422				regulator-state-mem {
423					regulator-on-in-suspend;
424					regulator-suspend-microvolt = <1800000>;
425				};
426			};
427
428			vdd2_ddr_s3: dcdc-reg9 {
429				regulator-always-on;
430				regulator-boot-on;
431				regulator-name = "vdd2_ddr_s3";
432				regulator-state-mem {
433					regulator-on-in-suspend;
434				};
435			};
436
437			vdd_ddr_s0: dcdc-reg10 {
438				regulator-always-on;
439				regulator-boot-on;
440				regulator-min-microvolt = <550000>;
441				regulator-max-microvolt = <1200000>;
442				regulator-name = "vdd_ddr_s0";
443				regulator-state-mem {
444					regulator-off-in-suspend;
445				};
446			};
447
448			vcca_1v8_s0: pldo-reg1 {
449				regulator-always-on;
450				regulator-boot-on;
451				regulator-min-microvolt = <1800000>;
452				regulator-max-microvolt = <1800000>;
453				regulator-name = "vcca_1v8_s0";
454				regulator-state-mem {
455					regulator-off-in-suspend;
456				};
457			};
458
459			vcca1v8_pldo2_s0: pldo-reg2 {
460				regulator-always-on;
461				regulator-boot-on;
462				regulator-min-microvolt = <1800000>;
463				regulator-max-microvolt = <1800000>;
464				regulator-name = "vcca1v8_pldo2_s0";
465				regulator-state-mem {
466					regulator-off-in-suspend;
467				};
468			};
469
470			vdda_1v2_s0: pldo-reg3 {
471				regulator-always-on;
472				regulator-boot-on;
473				regulator-min-microvolt = <1200000>;
474				regulator-max-microvolt = <1200000>;
475				regulator-name = "vdda_1v2_s0";
476				regulator-state-mem {
477					regulator-off-in-suspend;
478				};
479			};
480
481			vcca_3v3_s0: pldo-reg4 {
482				regulator-always-on;
483				regulator-boot-on;
484				regulator-min-microvolt = <3300000>;
485				regulator-max-microvolt = <3300000>;
486				regulator-name = "vcca_3v3_s0";
487				regulator-state-mem {
488					regulator-off-in-suspend;
489				};
490			};
491
492			vccio_sd_s0: pldo-reg5 {
493				regulator-always-on;
494				regulator-boot-on;
495				regulator-min-microvolt = <1800000>;
496				regulator-max-microvolt = <3300000>;
497				regulator-name = "vccio_sd_s0";
498				regulator-state-mem {
499					regulator-off-in-suspend;
500				};
501			};
502
503			vcca1v8_pldo6_s3: pldo-reg6 {
504				regulator-always-on;
505				regulator-boot-on;
506				regulator-min-microvolt = <1800000>;
507				regulator-max-microvolt = <1800000>;
508				regulator-name = "vcca1v8_pldo6_s3";
509				regulator-state-mem {
510					regulator-on-in-suspend;
511					regulator-suspend-microvolt = <1800000>;
512				};
513			};
514
515			vdd_0v75_s3: nldo-reg1 {
516				regulator-always-on;
517				regulator-boot-on;
518				regulator-min-microvolt = <750000>;
519				regulator-max-microvolt = <750000>;
520				regulator-name = "vdd_0v75_s3";
521				regulator-state-mem {
522					regulator-on-in-suspend;
523					regulator-suspend-microvolt = <750000>;
524				};
525			};
526
527			vdda_ddr_pll_s0: nldo-reg2 {
528				regulator-always-on;
529				regulator-boot-on;
530				regulator-min-microvolt = <850000>;
531				regulator-max-microvolt = <850000>;
532				regulator-name = "vdda_ddr_pll_s0";
533				regulator-state-mem {
534					regulator-off-in-suspend;
535				};
536			};
537
538			vdda0v75_hdmi_s0: nldo-reg3 {
539				regulator-always-on;
540				regulator-boot-on;
541				regulator-min-microvolt = <837500>;
542				regulator-max-microvolt = <837500>;
543				regulator-name = "vdda0v75_hdmi_s0";
544				regulator-state-mem {
545					regulator-off-in-suspend;
546				};
547			};
548
549			vdda_0v85_s0: nldo-reg4 {
550				regulator-always-on;
551				regulator-boot-on;
552				regulator-min-microvolt = <850000>;
553				regulator-max-microvolt = <850000>;
554				regulator-name = "vdda_0v85_s0";
555				regulator-state-mem {
556					regulator-off-in-suspend;
557				};
558			};
559
560			vdda_0v75_s0: nldo-reg5 {
561				regulator-always-on;
562				regulator-boot-on;
563				regulator-min-microvolt = <750000>;
564				regulator-max-microvolt = <750000>;
565				regulator-name = "vdda_0v75_s0";
566				regulator-state-mem {
567					regulator-off-in-suspend;
568				};
569			};
570		};
571	};
572};
573
574&i2c2 {
575	status = "okay";
576
577	hym8563: rtc@51 {
578		compatible = "haoyu,hym8563";
579		reg = <0x51>;
580		clock-output-names = "hym8563";
581		interrupt-parent = <&gpio0>;
582		interrupts = <RK_PB0 IRQ_TYPE_LEVEL_LOW>;
583		pinctrl-names = "default";
584		pinctrl-0 = <&hym8563_int>;
585		wakeup-source;
586		#clock-cells = <0>;
587	};
588};
589
590&mdio0 {
591	rgmii_phy0: phy@1 {
592		compatible = "ethernet-phy-ieee802.3-c22";
593		reg = <0x1>;
594		clocks = <&cru REFCLKO25M_GMAC0_OUT>;
595	};
596};
597
598&mdio1 {
599	rgmii_phy1: phy@1 {
600		compatible = "ethernet-phy-ieee802.3-c22";
601		reg = <0x1>;
602		clocks = <&cru REFCLKO25M_GMAC1_OUT>;
603	};
604};
605
606&pinctrl {
607	headphone {
608		hp_det: hp-det {
609			rockchip,pins = <0 RK_PD3 RK_FUNC_GPIO &pcfg_pull_up>;
610		};
611	};
612
613	hym8563 {
614		hym8563_int: hym8563-int {
615			rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_up>;
616		};
617	};
618
619	leds {
620		led_rgb_r: led-red-en {
621			rockchip,pins = <4 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>;
622		};
623		led_rgb_g: led-green-en {
624			rockchip,pins = <4 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>;
625		};
626	};
627};
628
629&sdhci {
630	bus-width = <8>;
631	full-pwr-cycle-in-suspend;
632	max-frequency = <200000000>;
633	mmc-hs400-1_8v;
634	mmc-hs400-enhanced-strobe;
635	no-sdio;
636	no-sd;
637	non-removable;
638	status = "okay";
639};
640
641&sdmmc {
642	bus-width = <4>;
643	cap-mmc-highspeed;
644	cap-sd-highspeed;
645	disable-wp;
646	max-frequency = <200000000>;
647	no-sdio;
648	no-mmc;
649	sd-uhs-sdr104;
650	vmmc-supply = <&vcc_3v3_s3>;
651	vqmmc-supply = <&vccio_sd_s0>;
652	status = "okay";
653};
654
655&uart0 {
656	pinctrl-0 = <&uart0m0_xfer>;
657	status = "okay";
658};
659