1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
3 * Copyright (c) 2019 Akash Gajjar <Akash_Gajjar@mentor.com>
4 * Copyright (c) 2019 Pragnesh Patel <Pragnesh_Patel@mentor.com>
8 #include <dt-bindings/input/linux-event-codes.h>
9 #include <dt-bindings/leds/common.h>
10 #include <dt-bindings/pwm/pwm.h>
11 #include "rk3399.dtsi"
20 stdout-path = "serial2:1500000n8";
23 clkin_gmac: external-gmac-clock {
24 compatible = "fixed-clock";
25 clock-frequency = <125000000>;
26 clock-output-names = "clkin_gmac";
31 compatible = "gpio-leds";
32 pinctrl-names = "default";
33 pinctrl-0 = <&user_led2>;
37 function = LED_FUNCTION_STATUS;
38 color = <LED_COLOR_ID_BLUE>;
39 gpios = <&gpio3 RK_PD5 GPIO_ACTIVE_HIGH>;
40 linux,default-trigger = "heartbeat";
44 sdio_pwrseq: sdio-pwrseq {
45 compatible = "mmc-pwrseq-simple";
48 pinctrl-names = "default";
49 pinctrl-0 = <&wifi_enable_h>;
50 reset-gpios = <&gpio0 RK_PB2 GPIO_ACTIVE_LOW>;
54 compatible = "audio-graph-card";
60 compatible = "audio-graph-card";
66 compatible = "linux,spdif-dit";
67 #sound-dai-cells = <0>;
71 remote-endpoint = <&spdif_p0_0>;
76 vbus_typec: vbus-typec-regulator {
77 compatible = "regulator-fixed";
79 gpio = <&gpio1 RK_PA3 GPIO_ACTIVE_HIGH>;
80 pinctrl-names = "default";
81 pinctrl-0 = <&vcc5v0_typec_en>;
82 regulator-name = "vbus_typec";
84 vin-supply = <&vcc5v0_sys>;
88 compatible = "regulator-fixed";
89 regulator-name = "vcc12v_dcin";
92 regulator-min-microvolt = <12000000>;
93 regulator-max-microvolt = <12000000>;
96 vcc3v3_lan: vcc3v3-lan-regulator {
97 compatible = "regulator-fixed";
98 regulator-name = "vcc3v3_lan";
101 regulator-min-microvolt = <3300000>;
102 regulator-max-microvolt = <3300000>;
103 vin-supply = <&vcc3v3_sys>;
106 vcc3v3_pcie: vcc3v3-pcie-regulator {
107 compatible = "regulator-fixed";
109 gpio = <&gpio2 RK_PD2 GPIO_ACTIVE_HIGH>;
110 pinctrl-names = "default";
111 pinctrl-0 = <&pcie_pwr_en>;
112 regulator-name = "vcc3v3_pcie";
115 vin-supply = <&vcc5v0_sys>;
118 vcc3v3_sys: vcc3v3-sys {
119 compatible = "regulator-fixed";
120 regulator-name = "vcc3v3_sys";
123 regulator-min-microvolt = <3300000>;
124 regulator-max-microvolt = <3300000>;
125 vin-supply = <&vcc5v0_sys>;
128 vcc5v0_host: vcc5v0-host-regulator {
129 compatible = "regulator-fixed";
131 gpio = <&gpio4 RK_PD1 GPIO_ACTIVE_HIGH>;
132 pinctrl-names = "default";
133 pinctrl-0 = <&vcc5v0_host_en>;
134 regulator-name = "vcc5v0_host";
136 vin-supply = <&vcc5v0_sys>;
139 vcc5v0_sys: vcc-sys {
140 compatible = "regulator-fixed";
141 regulator-name = "vcc5v0_sys";
144 regulator-min-microvolt = <5000000>;
145 regulator-max-microvolt = <5000000>;
146 vin-supply = <&vcc12v_dcin>;
150 compatible = "regulator-fixed";
151 regulator-name = "vcc_0v9";
154 regulator-min-microvolt = <900000>;
155 regulator-max-microvolt = <900000>;
156 vin-supply = <&vcc3v3_sys>;
160 compatible = "pwm-regulator";
161 pwms = <&pwm2 0 25000 1>;
162 pwm-supply = <&vcc5v0_sys>;
163 regulator-name = "vdd_log";
166 regulator-min-microvolt = <800000>;
167 regulator-max-microvolt = <1400000>;
172 cpu-supply = <&vdd_cpu_l>;
176 cpu-supply = <&vdd_cpu_l>;
180 cpu-supply = <&vdd_cpu_l>;
184 cpu-supply = <&vdd_cpu_l>;
188 cpu-supply = <&vdd_cpu_b>;
192 cpu-supply = <&vdd_cpu_b>;
200 assigned-clocks = <&cru SCLK_RMII_SRC>;
201 assigned-clock-parents = <&clkin_gmac>;
202 clock_in_out = "input";
203 phy-supply = <&vcc3v3_lan>;
205 pinctrl-names = "default";
206 pinctrl-0 = <&rgmii_pins>;
207 snps,reset-gpio = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>;
208 snps,reset-active-low;
209 snps,reset-delays-us = <0 10000 50000>;
216 mali-supply = <&vdd_gpu>;
221 avdd-0v9-supply = <&vcca0v9_hdmi>;
222 avdd-1v8-supply = <&vcca1v8_hdmi>;
223 ddc-i2c-bus = <&i2c3>;
224 pinctrl-names = "default";
225 pinctrl-0 = <&hdmi_cec>;
234 clock-frequency = <400000>;
235 i2c-scl-rising-time-ns = <168>;
236 i2c-scl-falling-time-ns = <4>;
240 compatible = "rockchip,rk808";
242 interrupt-parent = <&gpio1>;
243 interrupts = <21 IRQ_TYPE_LEVEL_LOW>;
245 clock-output-names = "xin32k", "rk808-clkout2";
246 pinctrl-names = "default";
247 pinctrl-0 = <&pmic_int_l>;
248 rockchip,system-power-controller;
251 vcc1-supply = <&vcc5v0_sys>;
252 vcc2-supply = <&vcc5v0_sys>;
253 vcc3-supply = <&vcc5v0_sys>;
254 vcc4-supply = <&vcc5v0_sys>;
255 vcc6-supply = <&vcc5v0_sys>;
256 vcc7-supply = <&vcc5v0_sys>;
257 vcc8-supply = <&vcc3v3_sys>;
258 vcc9-supply = <&vcc5v0_sys>;
259 vcc10-supply = <&vcc5v0_sys>;
260 vcc11-supply = <&vcc5v0_sys>;
261 vcc12-supply = <&vcc3v3_sys>;
262 vddio-supply = <&vcc_1v8>;
265 vdd_center: DCDC_REG1 {
266 regulator-name = "vdd_center";
269 regulator-min-microvolt = <750000>;
270 regulator-max-microvolt = <1350000>;
271 regulator-ramp-delay = <6001>;
272 regulator-state-mem {
273 regulator-off-in-suspend;
277 vdd_cpu_l: DCDC_REG2 {
278 regulator-name = "vdd_cpu_l";
281 regulator-min-microvolt = <750000>;
282 regulator-max-microvolt = <1350000>;
283 regulator-ramp-delay = <6001>;
284 regulator-state-mem {
285 regulator-off-in-suspend;
290 regulator-name = "vcc_ddr";
293 regulator-state-mem {
294 regulator-on-in-suspend;
299 regulator-name = "vcc_1v8";
302 regulator-min-microvolt = <1800000>;
303 regulator-max-microvolt = <1800000>;
304 regulator-state-mem {
305 regulator-on-in-suspend;
306 regulator-suspend-microvolt = <1800000>;
310 vcca1v8_codec: LDO_REG1 {
311 regulator-name = "vcca1v8_codec";
314 regulator-min-microvolt = <1800000>;
315 regulator-max-microvolt = <1800000>;
316 regulator-state-mem {
317 regulator-off-in-suspend;
321 vcca1v8_hdmi: LDO_REG2 {
322 regulator-name = "vcca1v8_hdmi";
325 regulator-min-microvolt = <1800000>;
326 regulator-max-microvolt = <1800000>;
327 regulator-state-mem {
328 regulator-off-in-suspend;
333 regulator-name = "vcca_1v8";
336 regulator-min-microvolt = <1800000>;
337 regulator-max-microvolt = <1800000>;
338 regulator-state-mem {
339 regulator-on-in-suspend;
340 regulator-suspend-microvolt = <1800000>;
345 regulator-name = "vcc_sdio";
348 regulator-min-microvolt = <3000000>;
349 regulator-max-microvolt = <3000000>;
350 regulator-state-mem {
351 regulator-on-in-suspend;
352 regulator-suspend-microvolt = <3000000>;
356 vcca3v0_codec: LDO_REG5 {
357 regulator-name = "vcca3v0_codec";
360 regulator-min-microvolt = <3000000>;
361 regulator-max-microvolt = <3000000>;
362 regulator-state-mem {
363 regulator-off-in-suspend;
368 regulator-name = "vcc_1v5";
371 regulator-min-microvolt = <1500000>;
372 regulator-max-microvolt = <1500000>;
373 regulator-state-mem {
374 regulator-on-in-suspend;
375 regulator-suspend-microvolt = <1500000>;
379 vcca0v9_hdmi: LDO_REG7 {
380 regulator-name = "vcca0v9_hdmi";
383 regulator-min-microvolt = <900000>;
384 regulator-max-microvolt = <900000>;
385 regulator-state-mem {
386 regulator-off-in-suspend;
391 regulator-name = "vcc_3v0";
394 regulator-min-microvolt = <3000000>;
395 regulator-max-microvolt = <3000000>;
396 regulator-state-mem {
397 regulator-on-in-suspend;
398 regulator-suspend-microvolt = <3000000>;
402 vcc_cam: SWITCH_REG1 {
403 regulator-name = "vcc_cam";
406 regulator-state-mem {
407 regulator-off-in-suspend;
411 vcc_mipi: SWITCH_REG2 {
412 regulator-name = "vcc_mipi";
415 regulator-state-mem {
416 regulator-off-in-suspend;
422 vdd_cpu_b: regulator@40 {
423 compatible = "silergy,syr827";
425 fcs,suspend-voltage-selector = <1>;
426 pinctrl-names = "default";
427 pinctrl-0 = <&vsel1_pin>;
428 regulator-name = "vdd_cpu_b";
429 regulator-min-microvolt = <712500>;
430 regulator-max-microvolt = <1500000>;
431 regulator-ramp-delay = <1000>;
434 vin-supply = <&vcc5v0_sys>;
436 regulator-state-mem {
437 regulator-off-in-suspend;
441 vdd_gpu: regulator@41 {
442 compatible = "silergy,syr828";
444 fcs,suspend-voltage-selector = <1>;
445 pinctrl-names = "default";
446 pinctrl-0 = <&vsel2_pin>;
447 regulator-name = "vdd_gpu";
448 regulator-min-microvolt = <712500>;
449 regulator-max-microvolt = <1500000>;
450 regulator-ramp-delay = <1000>;
453 vin-supply = <&vcc5v0_sys>;
455 regulator-state-mem {
456 regulator-off-in-suspend;
462 i2c-scl-rising-time-ns = <300>;
463 i2c-scl-falling-time-ns = <15>;
467 compatible = "everest,es8316";
469 clocks = <&cru SCLK_I2S_8CH_OUT>;
470 clock-names = "mclk";
471 #sound-dai-cells = <0>;
474 es8316_p0_0: endpoint {
475 remote-endpoint = <&i2s0_p0_0>;
482 i2c-scl-rising-time-ns = <450>;
483 i2c-scl-falling-time-ns = <15>;
488 i2c-scl-rising-time-ns = <600>;
489 i2c-scl-falling-time-ns = <20>;
494 pinctrl-0 = <&i2s0_2ch_bus>;
495 pinctrl-1 = <&i2s0_2ch_bus_bclk_off>;
496 rockchip,capture-channels = <2>;
497 rockchip,playback-channels = <2>;
501 i2s0_p0_0: endpoint {
504 remote-endpoint = <&es8316_p0_0>;
510 rockchip,playback-channels = <2>;
511 rockchip,capture-channels = <2>;
519 audio-supply = <&vcca1v8_codec>;
520 bt656-supply = <&vcc_3v0>;
521 gpio1830-supply = <&vcc_3v0>;
522 sdmmc-supply = <&vcc_sdio>;
527 ep-gpios = <&gpio4 RK_PD3 GPIO_ACTIVE_HIGH>;
529 pinctrl-0 = <&pcie_clkreqnb_cpm>;
530 pinctrl-names = "default";
531 vpcie0v9-supply = <&vcc_0v9>;
532 vpcie1v8-supply = <&vcc_1v8>;
533 vpcie3v3-supply = <&vcc3v3_pcie>;
543 bt_enable_h: bt-enable-h {
544 rockchip,pins = <0 RK_PB1 RK_FUNC_GPIO &pcfg_pull_none>;
547 bt_host_wake_l: bt-host-wake-l {
548 rockchip,pins = <0 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>;
551 bt_wake_l: bt-wake-l {
552 rockchip,pins = <2 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>;
557 hp_detect: hp-detect {
558 rockchip,pins = <1 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>;
562 rockchip,pins = <1 RK_PA1 RK_FUNC_GPIO &pcfg_pull_up>;
567 user_led2: user-led2 {
568 rockchip,pins = <3 RK_PD5 RK_FUNC_GPIO &pcfg_pull_none>;
573 pcie_pwr_en: pcie-pwr-en {
574 rockchip,pins = <2 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>;
579 pmic_int_l: pmic-int-l {
580 rockchip,pins = <1 RK_PC5 RK_FUNC_GPIO &pcfg_pull_up>;
583 vsel1_pin: vsel1-pin {
584 rockchip,pins = <1 RK_PC1 RK_FUNC_GPIO &pcfg_pull_down>;
587 vsel2_pin: vsel2-pin {
588 rockchip,pins = <1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_down>;
593 sdio0_bus4: sdio0-bus4 {
594 rockchip,pins = <2 RK_PC4 1 &pcfg_pull_up_20ma>,
595 <2 RK_PC5 1 &pcfg_pull_up_20ma>,
596 <2 RK_PC6 1 &pcfg_pull_up_20ma>,
597 <2 RK_PC7 1 &pcfg_pull_up_20ma>;
600 sdio0_cmd: sdio0-cmd {
601 rockchip,pins = <2 RK_PD0 1 &pcfg_pull_up_20ma>;
604 sdio0_clk: sdio0-clk {
605 rockchip,pins = <2 RK_PD1 1 &pcfg_pull_none_20ma>;
610 vcc5v0_typec_en: vcc5v0-typec-en {
611 rockchip,pins = <1 RK_PA3 RK_FUNC_GPIO &pcfg_pull_up>;
616 vcc5v0_host_en: vcc5v0-host-en {
617 rockchip,pins = <4 RK_PD1 RK_FUNC_GPIO &pcfg_pull_none>;
622 wifi_enable_h: wifi-enable-h {
623 rockchip,pins = <0 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>;
626 wifi_host_wake_l: wifi-host-wake-l {
627 rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>;
633 pmu1830-supply = <&vcc_3v0>;
644 vref-supply = <&vcc_1v8>;
648 max-frequency = <150000000>;
656 #address-cells = <1>;
659 clock-frequency = <50000000>;
662 keep-power-in-suspend;
663 mmc-pwrseq = <&sdio_pwrseq>;
665 pinctrl-names = "default";
666 pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>;
674 cd-gpios = <&gpio0 RK_PA7 GPIO_ACTIVE_LOW>;
676 max-frequency = <150000000>;
677 pinctrl-names = "default";
678 pinctrl-0 = <&sdmmc_clk &sdmmc_cd &sdmmc_cmd &sdmmc_bus4>;
685 spdif_p0_0: endpoint {
686 remote-endpoint = <&dit_p0_0>;
702 /* tshut mode 0:CRU 1:GPIO */
703 rockchip,hw-tshut-mode = <1>;
704 /* tshut polarity 0:LOW 1:HIGH */
705 rockchip,hw-tshut-polarity = <1>;
711 u2phy0_otg: otg-port {
715 u2phy0_host: host-port {
716 phy-supply = <&vcc5v0_host>;
724 u2phy1_otg: otg-port {
728 u2phy1_host: host-port {
729 phy-supply = <&vcc5v0_host>;
735 pinctrl-names = "default";
736 pinctrl-0 = <&uart0_xfer &uart0_cts &uart0_rts>;