blob: a78eb4ac6fff0082f5b1391ff5333a70778d96ba [file] [log] [blame]
Matwey V. Kornilov348a0b72019-06-09 00:27:16 +03001// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2/*
3 * Copyright (c) 2017 PINE64
4 */
5
6/dts-v1/;
7#include "rk3328.dtsi"
8
9/ {
10 model = "Pine64 Rock64";
11 compatible = "pine64,rock64", "rockchip,rk3328";
12
13 chosen {
14 stdout-path = "serial2:1500000n8";
15 };
16
17 gmac_clkin: external-gmac-clock {
18 compatible = "fixed-clock";
19 clock-frequency = <125000000>;
20 clock-output-names = "gmac_clkin";
21 #clock-cells = <0>;
22 };
23
24 vcc_sd: sdmmc-regulator {
25 compatible = "regulator-fixed";
26 gpio = <&gpio0 RK_PD6 GPIO_ACTIVE_LOW>;
27 pinctrl-names = "default";
28 pinctrl-0 = <&sdmmc0m1_gpio>;
29 regulator-name = "vcc_sd";
30 regulator-min-microvolt = <3300000>;
31 regulator-max-microvolt = <3300000>;
32 vin-supply = <&vcc_io>;
33 };
34
35 vcc_host_5v: vcc-host-5v-regulator {
36 compatible = "regulator-fixed";
Kever Yang08bbe442019-08-15 11:13:28 +080037 gpio = <&gpio0 RK_PA2 GPIO_ACTIVE_LOW>;
Matwey V. Kornilov348a0b72019-06-09 00:27:16 +030038 pinctrl-names = "default";
39 pinctrl-0 = <&usb20_host_drv>;
Kever Yang08bbe442019-08-15 11:13:28 +080040 regulator-name = "vcc_host_5v";
Matwey V. Kornilov348a0b72019-06-09 00:27:16 +030041 regulator-always-on;
42 regulator-boot-on;
43 vin-supply = <&vcc_sys>;
44 };
45
46 vcc_sys: vcc-sys {
47 compatible = "regulator-fixed";
48 regulator-name = "vcc_sys";
49 regulator-always-on;
50 regulator-boot-on;
51 regulator-min-microvolt = <5000000>;
52 regulator-max-microvolt = <5000000>;
53 };
54};
55
56&cpu0 {
57 cpu-supply = <&vdd_arm>;
58};
59
60&cpu1 {
61 cpu-supply = <&vdd_arm>;
62};
63
64&cpu2 {
65 cpu-supply = <&vdd_arm>;
66};
67
68&cpu3 {
69 cpu-supply = <&vdd_arm>;
70};
71
72&emmc {
73 bus-width = <8>;
74 cap-mmc-highspeed;
75 mmc-hs200-1_8v;
76 non-removable;
77 pinctrl-names = "default";
78 pinctrl-0 = <&emmc_clk &emmc_cmd &emmc_bus8>;
79 vmmc-supply = <&vcc_io>;
80 vqmmc-supply = <&vcc18_emmc>;
81 status = "okay";
82};
83
84&gmac2io {
85 assigned-clocks = <&cru SCLK_MAC2IO>, <&cru SCLK_MAC2IO_EXT>;
86 assigned-clock-parents = <&gmac_clkin>, <&gmac_clkin>;
87 clock_in_out = "input";
88 phy-supply = <&vcc_io>;
89 phy-mode = "rgmii";
90 pinctrl-names = "default";
91 pinctrl-0 = <&rgmiim1_pins>;
92 snps,force_thresh_dma_mode;
93 snps,reset-gpio = <&gpio1 RK_PC2 GPIO_ACTIVE_LOW>;
94 snps,reset-active-low;
95 snps,reset-delays-us = <0 10000 50000>;
96 tx_delay = <0x24>;
97 rx_delay = <0x18>;
98 status = "okay";
99};
100
101&i2c1 {
102 status = "okay";
103
104 rk805: rk805@18 {
105 compatible = "rockchip,rk805";
106 reg = <0x18>;
107 interrupt-parent = <&gpio2>;
108 interrupts = <6 IRQ_TYPE_LEVEL_LOW>;
109 #clock-cells = <1>;
110 clock-output-names = "xin32k", "rk805-clkout2";
111 pinctrl-names = "default";
112 pinctrl-0 = <&pmic_int_l>;
113 rockchip,system-power-controller;
114 wakeup-source;
115
116 vcc1-supply = <&vcc_sys>;
117 vcc2-supply = <&vcc_sys>;
118 vcc3-supply = <&vcc_sys>;
119 vcc4-supply = <&vcc_sys>;
120 vcc5-supply = <&vcc_io>;
121 vcc6-supply = <&vcc_sys>;
122
123 regulators {
124 vdd_logic: DCDC_REG1 {
125 regulator-name = "vdd_logic";
126 regulator-min-microvolt = <712500>;
127 regulator-max-microvolt = <1450000>;
128 regulator-ramp-delay = <12500>;
129 regulator-always-on;
130 regulator-boot-on;
131 regulator-state-mem {
132 regulator-on-in-suspend;
133 regulator-suspend-microvolt = <1000000>;
134 };
135 };
136
137 vdd_arm: DCDC_REG2 {
138 regulator-name = "vdd_arm";
139 regulator-min-microvolt = <712500>;
140 regulator-max-microvolt = <1450000>;
141 regulator-ramp-delay = <12500>;
142 regulator-always-on;
143 regulator-boot-on;
144 regulator-state-mem {
145 regulator-on-in-suspend;
146 regulator-suspend-microvolt = <950000>;
147 };
148 };
149
150 vcc_ddr: DCDC_REG3 {
151 regulator-name = "vcc_ddr";
152 regulator-always-on;
153 regulator-boot-on;
154 regulator-state-mem {
155 regulator-on-in-suspend;
156 };
157 };
158
159 vcc_io: DCDC_REG4 {
160 regulator-name = "vcc_io";
161 regulator-min-microvolt = <3300000>;
162 regulator-max-microvolt = <3300000>;
163 regulator-always-on;
164 regulator-boot-on;
165 regulator-state-mem {
166 regulator-on-in-suspend;
167 regulator-suspend-microvolt = <3300000>;
168 };
169 };
170
171 vcc_18: LDO_REG1 {
172 regulator-name = "vdd_18";
173 regulator-min-microvolt = <1800000>;
174 regulator-max-microvolt = <1800000>;
175 regulator-always-on;
176 regulator-boot-on;
177 regulator-state-mem {
178 regulator-on-in-suspend;
179 regulator-suspend-microvolt = <1800000>;
180 };
181 };
182
183 vcc18_emmc: LDO_REG2 {
184 regulator-name = "vcc_18emmc";
185 regulator-min-microvolt = <1800000>;
186 regulator-max-microvolt = <1800000>;
187 regulator-always-on;
188 regulator-boot-on;
189 regulator-state-mem {
190 regulator-on-in-suspend;
191 regulator-suspend-microvolt = <1800000>;
192 };
193 };
194
195 vdd_10: LDO_REG3 {
196 regulator-name = "vdd_10";
197 regulator-min-microvolt = <1000000>;
198 regulator-max-microvolt = <1000000>;
199 regulator-always-on;
200 regulator-boot-on;
201 regulator-state-mem {
202 regulator-on-in-suspend;
203 regulator-suspend-microvolt = <1000000>;
204 };
205 };
206 };
207 };
208};
209
210&io_domains {
211 status = "okay";
212
213 vccio1-supply = <&vcc_io>;
214 vccio2-supply = <&vcc18_emmc>;
215 vccio3-supply = <&vcc_io>;
216 vccio4-supply = <&vcc_18>;
217 vccio5-supply = <&vcc_io>;
218 vccio6-supply = <&vcc_io>;
219 pmuio-supply = <&vcc_io>;
220};
221
222&pinctrl {
223 pmic {
224 pmic_int_l: pmic-int-l {
225 rockchip,pins = <2 RK_PA6 RK_FUNC_GPIO &pcfg_pull_up>;
226 };
227 };
228
229 usb2 {
230 usb20_host_drv: usb20-host-drv {
231 rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>;
232 };
233 };
Matwey V. Kornilov348a0b72019-06-09 00:27:16 +0300234};
235
236&sdmmc {
237 bus-width = <4>;
238 cap-mmc-highspeed;
239 cap-sd-highspeed;
240 disable-wp;
241 max-frequency = <150000000>;
242 pinctrl-names = "default";
243 pinctrl-0 = <&sdmmc0_clk &sdmmc0_cmd &sdmmc0_dectn &sdmmc0_bus4>;
244 vmmc-supply = <&vcc_sd>;
245 status = "okay";
246};
247
248&spi0 {
249 status = "okay";
250
251 spiflash@0 {
252 compatible = "jedec,spi-nor";
253 reg = <0>;
254
255 /* maximum speed for Rockchip SPI */
256 spi-max-frequency = <50000000>;
257 };
258};
259
260&uart2 {
261 status = "okay";
262};
263
264&usb20_otg {
265 dr_mode = "host";
266 status = "okay";
267};
268
269&usb_host0_ehci {
270 status = "okay";
271};
272
273&usb_host0_ohci {
274 status = "okay";
275};