1 // SPDX-License-Identifier: GPL-2.0+ OR X11
3 * (C) Copyright 2017 Theobroma Systems Design und Consulting GmbH
6 #include <dt-bindings/pwm/pwm.h>
10 model = "Theobroma Systems RK3399-Q7 SoM";
11 compatible = "tsd,rk3399-q7", "tsd,puma", "rockchip,rk3399";
14 u-boot,spl-payload-offset = <0x40000>; /* @ 256KB */
15 u-boot,mmc-env-offset = <0x4000>; /* @ 16KB */
16 u-boot,efi-partition-entries-offset = <0x200000>; /* 2MB */
17 u-boot,boot-led = "module_led";
18 sysreset-gpio = <&gpio1 RK_PA6 GPIO_ACTIVE_HIGH>;
22 stdout-path = "serial0:115200n8";
23 u-boot,spl-boot-order = \
24 "same-as-spl", &spiflash, &sdhci, &sdmmc;
33 compatible = "gpio-leds";
34 pinctrl-names = "default";
35 pinctrl-0 = <&leds_pins_puma>;
39 gpios = <&gpio2 RK_PD1 GPIO_ACTIVE_HIGH>;
40 linux,default-trigger = "heartbeat";
44 label = "sd_card_led";
45 gpios = <&gpio1 RK_PA2 GPIO_ACTIVE_HIGH>;
46 linux,default-trigger = "mmc0";
50 clkin_gmac: external-gmac-clock {
51 compatible = "fixed-clock";
52 clock-frequency = <125000000>;
53 clock-output-names = "clkin_gmac";
57 dw_hdmi_audio: dw-hdmi-audio {
59 compatible = "rockchip,dw-hdmi-audio";
60 #sound-dai-cells = <0>;
63 hdmi_codec: hdmi-codec {
64 compatible = "simple-audio-card";
65 simple-audio-card,format = "i2s";
66 simple-audio-card,mclk-fs = <256>;
67 simple-audio-card,name = "HDMI-CODEC";
69 simple-audio-card,cpu {
73 simple-audio-card,codec {
78 hdmi_sound: hdmi-sound {
80 compatible = "simple-audio-card";
81 simple-audio-card,format = "i2s";
82 simple-audio-card,mclk-fs = <256>;
83 simple-audio-card,name = "rockchip,hdmi";
85 simple-audio-card,cpu {
88 simple-audio-card,codec {
93 usbhub_enable: usbhub_enable {
94 compatible = "regulator-fixed";
95 regulator-name = "usbhub_enable";
97 gpio = <&gpio4 RK_PA3 GPIO_ACTIVE_LOW>;
98 pinctrl-names = "default";
99 pinctrl-0 = <&host_vbus_drv>;
101 regulator-min-microvolt = <3300000>;
102 regulator-max-microvolt = <3300000>;
106 * The Qseven BIOS_DISABLE signal on the RK3399-Q7 keeps the on-module
107 * eMMC and SPI flash powered-down initially (in fact it keeps the
108 * reset signal asserted). Even though it is an enable signal, we
109 * model this as a regulator.
111 bios_enable: bios_enable {
112 compatible = "regulator-fixed";
114 regulator-name = "bios_enable";
116 gpio = <&gpio3 RK_PD5 GPIO_ACTIVE_LOW>;
119 regulator-min-microvolt = <1800000>;
120 regulator-max-microvolt = <1800000>;
123 vccadc_ref: vccadc-ref {
124 compatible = "regulator-fixed";
125 regulator-name = "vcc1v8_sys";
128 regulator-min-microvolt = <1800000>;
129 regulator-max-microvolt = <1800000>;
132 vcc3v3_sys: vcc3v3-sys {
133 compatible = "regulator-fixed";
134 regulator-name = "vcc3v3_sys";
137 regulator-min-microvolt = <3300000>;
138 regulator-max-microvolt = <3300000>;
141 vcc5v0_otg: vcc5v0-otg-regulator {
142 compatible = "regulator-fixed";
144 gpio = <&gpio0 RK_PA2 GPIO_ACTIVE_HIGH>;
145 pinctrl-names = "default";
146 pinctrl-0 = <&otg_vbus_drv>;
147 regulator-name = "vcc5v0_otg";
151 vcc5v0_sys: vcc5v0-sys {
152 compatible = "regulator-fixed";
153 regulator-name = "vcc5v0_sys";
156 regulator-min-microvolt = <5000000>;
157 regulator-max-microvolt = <5000000>;
160 vcc_phy: vcc-phy-regulator {
161 compatible = "regulator-fixed";
162 regulator-name = "vcc_phy";
168 compatible = "pwm-regulator";
169 pwms = <&pwm2 0 25000 1>;
170 regulator-name = "vdd_log";
171 regulator-min-microvolt = <800000>;
172 regulator-max-microvolt = <1400000>;
176 /* for rockchip boot on */
177 rockchip,pwm_id= <2>;
178 rockchip,pwm_voltage = <1000000>;
187 phy-supply = <&vcc_phy>;
189 clock_in_out = "input";
190 snps,reset-gpio = <&gpio3 RK_PC0 GPIO_ACTIVE_LOW>;
191 snps,reset-active-low;
192 snps,reset-delays-us = <2 10000 50000>;
193 assigned-clocks = <&cru SCLK_RMII_SRC>;
194 assigned-clock-parents = <&clkin_gmac>;
195 pinctrl-names = "default";
196 pinctrl-0 = <&rgmii_pins>;
203 #sound-dai-cells = <0>;
209 i2c-scl-rising-time-ns = <168>;
210 i2c-scl-falling-time-ns = <4>;
211 clock-frequency = <400000>;
215 compatible = "fcs,fan53555";
217 vsel-gpios = <&gpio1 RK_PB6 GPIO_ACTIVE_HIGH>;
218 vin-supply = <&vcc5v0_sys>;
219 regulator-compatible = "fan53555-reg";
220 regulator-name = "vdd_gpu";
221 regulator-min-microvolt = <600000>;
222 regulator-max-microvolt = <1230000>;
223 regulator-ramp-delay = <1000>;
224 fcs,suspend-voltage-selector = <1>;
227 regulator-initial-state = <3>;
228 regulator-state-mem {
229 regulator-off-in-suspend;
234 compatible = "rockchip,rk808";
236 interrupt-parent = <&gpio1>;
237 interrupts = <22 IRQ_TYPE_LEVEL_LOW>; // TODO check interrupt?
238 pinctrl-names = "default";
239 pinctrl-0 = <&pmic_int_l>;
240 rockchip,system-power-controller;
243 clock-output-names = "xin32k", "rk808-clkout2";
245 vcc1-supply = <&vcc5v0_sys>;
246 vcc2-supply = <&vcc5v0_sys>;
247 vcc3-supply = <&vcc5v0_sys>;
248 vcc4-supply = <&vcc5v0_sys>;
249 vcc6-supply = <&vcc5v0_sys>;
250 vcc7-supply = <&vcc5v0_sys>;
251 vcc8-supply = <&vcc3v3_sys>;
252 vcc9-supply = <&vcc5v0_sys>;
253 vcc10-supply = <&vcc5v0_sys>;
254 vcc11-supply = <&vcc5v0_sys>;
255 vcc12-supply = <&vcc3v3_sys>;
256 vddio-supply = <&vcc1v8_pmu>;
259 vdd_center: DCDC_REG1 {
262 regulator-min-microvolt = <750000>;
263 regulator-max-microvolt = <1350000>;
264 regulator-ramp-delay = <6001>;
265 regulator-name = "vdd_center";
266 regulator-state-mem {
267 regulator-off-in-suspend;
271 vdd_cpu_l: DCDC_REG2 {
274 regulator-min-microvolt = <750000>;
275 regulator-max-microvolt = <1350000>;
276 regulator-ramp-delay = <6001>;
277 regulator-name = "vdd_cpu_l";
278 regulator-state-mem {
279 regulator-off-in-suspend;
286 regulator-name = "vcc_ddr";
287 regulator-state-mem {
288 regulator-on-in-suspend;
295 regulator-min-microvolt = <1800000>;
296 regulator-max-microvolt = <1800000>;
297 regulator-name = "vcc_1v8";
298 regulator-state-mem {
299 regulator-on-in-suspend;
300 regulator-suspend-microvolt = <1800000>;
306 regulator-min-microvolt = <1800000>;
307 regulator-max-microvolt = <1800000>;
308 regulator-name = "vcc_ldo1";
309 regulator-state-mem {
310 regulator-off-in-suspend;
314 vcc1v8_hdmi: LDO_REG2 {
317 regulator-min-microvolt = <1800000>;
318 regulator-max-microvolt = <1800000>;
319 regulator-name = "vcc1v8_hdmi";
320 regulator-state-mem {
321 regulator-off-in-suspend;
325 vcc1v8_pmu: LDO_REG3 {
328 regulator-min-microvolt = <1800000>;
329 regulator-max-microvolt = <1800000>;
330 regulator-name = "vcc1v8_pmu";
331 regulator-state-mem {
332 regulator-on-in-suspend;
333 regulator-suspend-microvolt = <1800000>;
340 regulator-min-microvolt = <1800000>;
341 regulator-max-microvolt = <3000000>;
342 regulator-name = "vcc_sd";
343 regulator-state-mem {
344 regulator-on-in-suspend;
345 regulator-suspend-microvolt = <3000000>;
351 regulator-min-microvolt = <3000000>;
352 regulator-max-microvolt = <3000000>;
353 regulator-name = "vcc_ldo5";
354 regulator-state-mem {
355 regulator-off-in-suspend;
361 regulator-min-microvolt = <1500000>;
362 regulator-max-microvolt = <1500000>;
363 regulator-name = "vcc_ldo6";
364 regulator-state-mem {
365 regulator-off-in-suspend;
369 vcc0v9_hdmi: LDO_REG7 {
372 regulator-min-microvolt = <900000>;
373 regulator-max-microvolt = <900000>;
374 regulator-name = "vcc0v9_hdmi";
375 regulator-state-mem {
376 regulator-off-in-suspend;
380 vcc_efuse: LDO_REG8 {
383 regulator-min-microvolt = <1800000>;
384 regulator-max-microvolt = <1800000>;
385 regulator-name = "vcc_efuse";
386 regulator-state-mem {
387 regulator-off-in-suspend;
391 vcc3v3_s3: SWITCH_REG1 {
394 regulator-name = "vcc3v3_s3";
395 regulator-state-mem {
396 regulator-off-in-suspend;
400 vcc3v3_s0: SWITCH_REG2 {
403 regulator-name = "vcc3v3_s0";
404 regulator-state-mem {
405 regulator-off-in-suspend;
414 clock-frequency = <400000>;
416 vdd_cpu_b: vdd_cpu_b {
418 compatible = "fcs,fan53555";
420 vsel-gpios = <&gpio1 RK_PA4 GPIO_ACTIVE_HIGH>;
421 vin-supply = <&vcc5v0_sys>;
422 regulator-compatible = "fan53555-reg";
423 regulator-name = "vdd_cpu_b";
424 regulator-min-microvolt = <600000>;
425 regulator-max-microvolt = <1230000>;
426 regulator-ramp-delay = <1000>;
427 fcs,suspend-voltage-selector = <1>;
430 regulator-initial-state = <3>;
431 regulator-state-mem {
432 regulator-off-in-suspend;
439 rockchip,i2s-broken-burst-len;
440 rockchip,playback-channels = <8>;
441 rockchip,capture-channels = <8>;
442 #sound-dai-cells = <0>;
446 #sound-dai-cells = <0>;
453 bt656-supply = <&vcc_1v8>; /* bt656_gpio2ab_ms */
454 audio-supply = <&vcc_1v8>; /* audio_gpio3d4a_ms */
455 sdmmc-supply = <&vcc_sd>; /* sdmmc_gpio4b_ms */
456 gpio1830-supply = <&vcc_1v8>; /* gpio1833_gpio4cd_ms */
460 assigned-clocks = <&cru SCLK_PCIEPHY_REF>;
461 assigned-clock-parents = <&cru SCLK_PCIEPHY_REF100M>;
462 assigned-clock-rates = <100000000>;
463 ep-gpios = <&gpio4 RK_PC6 GPIO_ACTIVE_HIGH>;
465 pinctrl-names = "default";
466 pinctrl-0 = <&pcie_clkreqn>;
476 pmu1830-supply = <&vcc_1v8>;
492 keep-power-in-suspend;
493 mmc-hs400-enhanced-strobe;
499 clock-frequency = <150000000>;
500 max-frequency = <40000000>;
507 vqmmc-supply = <&vcc_sd>;
508 pinctrl-names = "default";
509 pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_cd &sdmmc_bus4>;
539 tsd,usb-port-power = "usbhub_enable";
555 /* Pins that are not explicitely used by any devices */
556 pinctrl-names = "default";
557 pinctrl-0 = <&puma_pin_hog>;
560 puma_pin_hog: puma_pin_hog {
562 /* We need pull-ups on Q7 buttons */
563 <RK_GPIO0 RK_PA4 RK_FUNC_GPIO &pcfg_pull_up>, /* LID_BTN# */
564 <RK_GPIO0 RK_PB2 RK_FUNC_GPIO &pcfg_pull_up>, /* BATLOW# */
565 <RK_GPIO0 RK_PB3 RK_FUNC_GPIO &pcfg_pull_up>, /* SLP_BTN# */
566 <RK_GPIO0 RK_PB1 RK_FUNC_GPIO &pcfg_pull_up>; /* BIOS_DISABLE# */
571 pmic_int_l: pmic-int-l {
573 <RK_GPIO1 RK_PC6 RK_FUNC_GPIO &pcfg_pull_up>;
577 leds_pins_puma: led_pins@0 {
579 <RK_GPIO2 RK_PD1 RK_FUNC_GPIO &pcfg_pull_none>,
580 <RK_GPIO1 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
584 otg_vbus_drv: otg-vbus-drv {
586 <RK_GPIO0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
589 host_vbus_drv: host-vbus-drv {
591 <RK_GPIO4 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>;
596 i2c8_xfer_a: i2c8-xfer {
598 <RK_GPIO1 RK_PC5 RK_FUNC_1 &pcfg_pull_up>,
599 <RK_GPIO1 RK_PC4 RK_FUNC_1 &pcfg_pull_up>;
606 clock-frequency = <400000>;
610 clock-frequency = <400000>;
614 clock-frequency = <400000>;
618 clock-frequency = <400000>;
622 /* Enable pull-ups, the pins would float otherwise. */
624 <RK_GPIO2 RK_PB2 RK_FUNC_2 &pcfg_pull_up>,
625 <RK_GPIO2 RK_PB1 RK_FUNC_2 &pcfg_pull_up>;
630 clock-frequency = <400000>;
633 compatible = "isil,isl1208";
637 compatible = "ti,amc6821";
639 cooling-min-state = <0>;
640 cooling-max-state = <9>;
641 #cooling-cells = <2>;
647 pinctrl-names = "default";
648 pinctrl-0 = <&uart0_xfer &uart0_cts>;
658 #address-cells = <1>;
661 spiflash: w25q32dw@0 {
664 compatible = "spi-flash";
666 spi-max-frequency = <49500000>;