xref: /linux/arch/arm64/boot/dts/rockchip/rk3368-lion.dtsi (revision bfd5bb6f90af092aa345b15cd78143956a13c2a8)
1// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2/*
3 * Copyright (c) 2018 Theobroma Systems Design und Consulting GmbH
4 */
5
6/dts-v1/;
7#include "rk3368.dtsi"
8
9/ {
10	chosen {
11		stdout-path = "serial0:115200n8";
12	};
13
14	ext_gmac: gmac-clk {
15		compatible = "fixed-clock";
16		clock-frequency = <125000000>;
17		clock-output-names = "ext_gmac";
18		#clock-cells = <0>;
19	};
20
21	i2cmux1 {
22		compatible = "i2c-mux-gpio";
23		#address-cells = <1>;
24		#size-cells = <0>;
25		i2c-parent = <&i2c1>;
26		mux-gpios = <&gpio1 RK_PA7 GPIO_ACTIVE_HIGH>;
27
28		/* Q7_GPO_I2C */
29		i2c@0 {
30			reg = <0>;
31			#address-cells = <1>;
32			#size-cells = <0>;
33		};
34
35		/* Q7_SMB */
36		i2c@1 {
37			reg = <1>;
38			#address-cells = <1>;
39			#size-cells = <0>;
40		};
41	};
42
43	i2cmux2 {
44		compatible = "i2c-mux-gpio";
45		#address-cells = <1>;
46		#size-cells = <0>;
47		i2c-parent = <&i2c2>;
48		mux-gpios = <&gpio1 RK_PB4 GPIO_ACTIVE_HIGH>;
49
50		/* Q7_LVDS_BLC_I2C */
51		i2c@0 {
52			reg = <0>;
53			#address-cells = <1>;
54			#size-cells = <0>;
55
56			fan: fan@18 {
57				compatible = "ti,amc6821";
58				reg = <0x18>;
59				cooling-min-state = <0>;
60				cooling-max-state = <9>;
61				#cooling-cells = <2>;
62			};
63
64			rtc_twi: rtc@6f {
65				compatible = "isil,isl1208";
66				reg = <0x6f>;
67			};
68		};
69
70		/* Q7_GP2_I2C */
71		i2c@1 {
72			reg = <1>;
73			#address-cells = <1>;
74			#size-cells = <0>;
75		};
76	};
77
78	leds {
79		compatible = "gpio-leds";
80		pinctrl-names = "default";
81		pinctrl-0 = <&led_pins_module>;
82
83		module_led1 {
84			label = "module_led1";
85			gpios = <&gpio2 RK_PB5 GPIO_ACTIVE_HIGH>;
86			linux,default-trigger = "heartbeat";
87			panic-indicator;
88		};
89
90		module_led2 {
91			label = "module_led2";
92			gpios = <&gpio3 RK_PA3 GPIO_ACTIVE_HIGH>;
93			default-state = "off";
94		};
95	};
96
97	vcc_sys: vcc-sys-regulator {
98		compatible = "regulator-fixed";
99		regulator-name = "vcc_sys";
100		regulator-min-microvolt = <5000000>;
101		regulator-max-microvolt = <5000000>;
102		regulator-always-on;
103		regulator-boot-on;
104	};
105};
106
107&cpu_l0 {
108	cpu-supply = <&vdd_cpu>;
109};
110
111&cpu_l1 {
112	cpu-supply = <&vdd_cpu>;
113};
114
115&cpu_l2 {
116	cpu-supply = <&vdd_cpu>;
117};
118
119&cpu_l3 {
120	cpu-supply = <&vdd_cpu>;
121};
122
123&cpu_b0 {
124	cpu-supply = <&vdd_cpu>;
125};
126
127&cpu_b1 {
128	cpu-supply = <&vdd_cpu>;
129};
130
131&cpu_b2 {
132	cpu-supply = <&vdd_cpu>;
133};
134
135&cpu_b3 {
136	cpu-supply = <&vdd_cpu>;
137};
138
139&emmc {
140	bus-width = <8>;
141	clock-frequency = <150000000>;
142	disable-wp;
143	mmc-hs200-1_8v;
144	non-removable;
145	vmmc-supply = <&vcc33_io>;
146	vqmmc-supply = <&vcc18_io>;
147	pinctrl-names = "default";
148	pinctrl-0 = <&emmc_clk>, <&emmc_cmd>, <&emmc_bus8>;
149	status = "okay";
150};
151
152&gmac {
153	assigned-clocks = <&cru SCLK_MAC>;
154	assigned-clock-parents = <&ext_gmac>;
155	clock_in_out = "input";
156	phy-supply = <&vcc33_io>;
157	phy-mode = "rgmii";
158	pinctrl-names = "default";
159	pinctrl-0 = <&rgmii_pins>;
160	snps,reset-active-low;
161	snps,reset-delays-us = <0 10000 50000>;
162	snps,reset-gpio = <&gpio3 RK_PB3 GPIO_ACTIVE_HIGH>;
163	tx_delay = <0x10>;
164	rx_delay = <0x10>;
165	status = "okay";
166};
167
168&i2c0 {
169	status = "okay";
170
171	rk808: pmic@1b {
172		compatible = "rockchip,rk808";
173		reg = <0x1b>;
174		interrupt-parent = <&gpio0>;
175		interrupts = <RK_PA5 IRQ_TYPE_LEVEL_LOW>;
176		clock-output-names = "xin32k", "rk808-clkout2";
177		#clock-cells = <1>;
178		pinctrl-names = "default";
179		pinctrl-0 = <&pmic_int_l>, <&pmic_sleep>;
180		rockchip,system-power-controller;
181		vcc1-supply = <&vcc_sys>;
182		vcc2-supply = <&vcc_sys>;
183		vcc3-supply = <&vcc_sys>;
184		vcc4-supply = <&vcc_sys>;
185		vcc6-supply = <&vcc_sys>;
186		vcc7-supply = <&vcc_sys>;
187		vcc8-supply = <&vcc_sys>;
188		vcc9-supply = <&vcc_sys>;
189		vcc10-supply = <&vcc_sys>;
190		vcc11-supply = <&vcc_sys>;
191		vcc12-supply = <&vcc_sys>;
192
193		regulators {
194			vdd_cpu: DCDC_REG1 {
195				regulator-name = "vdd_cpu";
196				regulator-min-microvolt = <700000>;
197				regulator-max-microvolt = <1500000>;
198				regulator-always-on;
199				regulator-boot-on;
200			};
201
202			vdd_log: DCDC_REG2 {
203				regulator-name = "vdd_log";
204				regulator-min-microvolt = <700000>;
205				regulator-max-microvolt = <1500000>;
206				regulator-always-on;
207				regulator-boot-on;
208			};
209
210			vcc_ddr: DCDC_REG3 {
211				regulator-name = "vcc_ddr";
212				regulator-always-on;
213				regulator-boot-on;
214			};
215
216			vcc33_io: DCDC_REG4 {
217				regulator-name = "vcc33_io";
218				regulator-min-microvolt = <3300000>;
219				regulator-max-microvolt = <3300000>;
220				regulator-always-on;
221				regulator-boot-on;
222			};
223
224			vcc33_video: LDO_REG2 {
225				regulator-name = "vcc33_video";
226				regulator-min-microvolt = <3300000>;
227				regulator-max-microvolt = <3300000>;
228				regulator-always-on;
229				regulator-boot-on;
230			};
231
232			vdd10_pll: LDO_REG3 {
233				regulator-name = "vdd10_pll";
234				regulator-min-microvolt = <1000000>;
235				regulator-max-microvolt = <1000000>;
236				regulator-always-on;
237				regulator-boot-on;
238			};
239
240			vcc18_io: LDO_REG4 {
241				regulator-name = "vcc18_io";
242				regulator-min-microvolt = <1800000>;
243				regulator-max-microvolt = <1800000>;
244				regulator-boot-on;
245			};
246
247			vdd10_video: LDO_REG6 {
248				regulator-name = "vdd10_video";
249				regulator-min-microvolt = <1000000>;
250				regulator-max-microvolt = <1000000>;
251				regulator-always-on;
252				regulator-boot-on;
253			};
254
255			vcc18_video: LDO_REG8 {
256				regulator-name = "vcc18_video";
257				regulator-min-microvolt = <1800000>;
258				regulator-max-microvolt = <1800000>;
259				regulator-always-on;
260				regulator-boot-on;
261			};
262		};
263	};
264};
265
266&i2c1 {
267	status = "okay";
268};
269
270&i2c2 {
271	status = "okay";
272};
273
274&pinctrl {
275	leds {
276		led_pins_module: led-module-gpio {
277			rockchip,pins =
278				<RK_GPIO2 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>,
279				<RK_GPIO3 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>;
280		};
281	};
282	pmic {
283		pmic_int_l: pmic-int-l {
284			rockchip,pins = <RK_GPIO0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>;
285		};
286
287		pmic_sleep: pmic-sleep {
288			rockchip,pins = <RK_GPIO0 RK_PA0 RK_FUNC_2 &pcfg_pull_none>;
289		};
290	};
291};
292
293&spi1 {
294	status = "okay";
295
296	norflash: flash@0 {
297		compatible = "jedec,spi-nor";
298		reg = <0>;
299		spi-max-frequency = <50000000>;
300	};
301};
302
303&uart1 {
304	status = "okay";
305};
306
307&uart3 {
308	status = "okay";
309};
310
311&usb_host0_ehci {
312	status = "okay";
313};
314
315&wdt {
316	status = "okay";
317};
318