xref: /linux/arch/arm/boot/dts/renesas/r8a7790-stout.dts (revision fcc79e1714e8c2b8e216dc3149812edd37884eef)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * Device Tree Source for the Stout board
4 *
5 * Copyright (C) 2018 Marek Vasut <marek.vasut@gmail.com>
6 */
7
8/dts-v1/;
9#include "r8a7790.dtsi"
10#include <dt-bindings/gpio/gpio.h>
11#include <dt-bindings/input/input.h>
12
13/ {
14	model = "Stout";
15	compatible = "renesas,stout", "renesas,r8a7790";
16
17	aliases {
18		serial0 = &scifa0;
19	};
20
21	chosen {
22		bootargs = "ignore_loglevel rw root=/dev/nfs ip=on";
23		stdout-path = "serial0:115200n8";
24	};
25
26	memory@40000000 {
27		device_type = "memory";
28		reg = <0 0x40000000 0 0x40000000>;
29	};
30
31	leds {
32		compatible = "gpio-leds";
33		led1 {
34			gpios = <&gpio4 22 GPIO_ACTIVE_LOW>;
35		};
36		led2 {
37			gpios = <&gpio4 23 GPIO_ACTIVE_LOW>;
38		};
39		led3 {
40			gpios = <&gpio5 17 GPIO_ACTIVE_LOW>;
41		};
42		led5 {
43			gpios = <&gpio4 24 GPIO_ACTIVE_LOW>;
44		};
45	};
46
47	fixedregulator1v8: regulator-1v8 {
48		compatible = "regulator-fixed";
49		regulator-name = "fixed-1.8V";
50		regulator-min-microvolt = <1800000>;
51		regulator-max-microvolt = <1800000>;
52		regulator-boot-on;
53		regulator-always-on;
54	};
55
56	fixedregulator3v3: regulator-3v3 {
57		compatible = "regulator-fixed";
58		regulator-name = "fixed-3.3V";
59		regulator-min-microvolt = <3300000>;
60		regulator-max-microvolt = <3300000>;
61		regulator-boot-on;
62		regulator-always-on;
63	};
64
65	vcc_sdhi0: regulator-vcc-sdhi0 {
66		compatible = "regulator-fixed";
67
68		regulator-name = "SDHI0 Vcc";
69		regulator-min-microvolt = <3300000>;
70		regulator-max-microvolt = <3300000>;
71
72		gpio = <&gpio5 24 GPIO_ACTIVE_HIGH>;
73		enable-active-high;
74	};
75
76	hdmi-out {
77		compatible = "hdmi-connector";
78		type = "a";
79
80		port {
81			hdmi_con_out: endpoint {
82				remote-endpoint = <&adv7511_out>;
83			};
84		};
85	};
86
87	osc1_clk: osc1-clock {
88		compatible = "fixed-clock";
89		#clock-cells = <0>;
90		clock-frequency = <148500000>;
91	};
92
93	osc4_clk: osc4-clock {
94		compatible = "fixed-clock";
95		#clock-cells = <0>;
96		clock-frequency = <12000000>;
97	};
98};
99
100&du {
101	pinctrl-0 = <&du_pins>;
102	pinctrl-names = "default";
103	status = "okay";
104
105	clocks = <&cpg CPG_MOD 724>, <&cpg CPG_MOD 723>, <&cpg CPG_MOD 722>,
106		 <&osc1_clk>;
107	clock-names = "du.0", "du.1", "du.2", "dclkin.0";
108
109	ports {
110		port@0 {
111			endpoint {
112				remote-endpoint = <&adv7511_in>;
113			};
114		};
115	};
116};
117
118&lvds0 {
119	ports {
120		port@1 {
121			lvds_connector0: endpoint {
122			};
123		};
124	};
125};
126
127&lvds1 {
128	ports {
129		port@1 {
130			lvds_connector1: endpoint {
131			};
132		};
133	};
134};
135
136&extal_clk {
137	clock-frequency = <20000000>;
138};
139
140&pfc {
141
142	pinctrl-0 = <&scif_clk_pins>;
143	pinctrl-names = "default";
144
145	du_pins: du {
146		groups = "du_rgb888", "du_sync_1", "du_clk_out_0";
147		function = "du";
148	};
149
150	scifa0_pins: scifa0 {
151		groups = "scifa0_data_b";
152		function = "scifa0";
153	};
154
155	scif_clk_pins: scif_clk {
156		groups = "scif_clk";
157		function = "scif_clk";
158	};
159
160	ether_pins: ether {
161		groups = "eth_link", "eth_mdio", "eth_rmii";
162		function = "eth";
163	};
164
165	phy1_pins: phy1 {
166		groups = "intc_irq1";
167		function = "intc";
168	};
169
170	sdhi0_pins: sd0 {
171		groups = "sdhi0_data4", "sdhi0_ctrl";
172		function = "sdhi0";
173		power-source = <3300>;
174	};
175
176	qspi_pins: qspi {
177		groups = "qspi_ctrl", "qspi_data4";
178		function = "qspi";
179	};
180
181	iic2_pins: iic2 {
182		groups = "iic2_b";
183		function = "iic2";
184	};
185
186	iic3_pins: iic3 {
187		groups = "iic3";
188		function = "iic3";
189	};
190
191	pmic_irq_pins: pmicirq {
192		groups = "intc_irq2";
193		function = "intc";
194	};
195
196	usb0_pins: usb0 {
197		groups = "usb0";
198		function = "usb0";
199	};
200};
201
202&ether {
203	pinctrl-0 = <&ether_pins>, <&phy1_pins>;
204	pinctrl-names = "default";
205
206	phy-handle = <&phy1>;
207	renesas,ether-link-active-low;
208	status = "okay";
209
210	phy1: ethernet-phy@1 {
211		compatible = "ethernet-phy-id0022.1537",
212			     "ethernet-phy-ieee802.3-c22";
213		reg = <1>;
214		interrupts-extended = <&irqc0 1 IRQ_TYPE_LEVEL_LOW>;
215		micrel,led-mode = <1>;
216		reset-gpios = <&gpio3 31 GPIO_ACTIVE_LOW>;
217	};
218};
219
220&cmt0 {
221	status = "okay";
222};
223
224&qspi {
225	pinctrl-0 = <&qspi_pins>;
226	pinctrl-names = "default";
227
228	status = "okay";
229
230	flash: flash@0 {
231		compatible = "spansion,s25fl512s", "jedec,spi-nor";
232		reg = <0>;
233		spi-max-frequency = <30000000>;
234		spi-tx-bus-width = <4>;
235		spi-rx-bus-width = <4>;
236		spi-cpha;
237		spi-cpol;
238		m25p,fast-read;
239
240		partitions {
241			compatible = "fixed-partitions";
242			#address-cells = <1>;
243			#size-cells = <1>;
244
245			partition@0 {
246				label = "loader";
247				reg = <0x00000000 0x00080000>;
248				read-only;
249			};
250			partition@80000 {
251				label = "uboot";
252				reg = <0x00080000 0x00040000>;
253				read-only;
254			};
255			partition@c0000 {
256				label = "uboot-env";
257				reg = <0x000c0000 0x00040000>;
258				read-only;
259			};
260			partition@100000 {
261				label = "flash";
262				reg = <0x00100000 0x03f00000>;
263			};
264		};
265	};
266};
267
268&scifa0 {
269	pinctrl-0 = <&scifa0_pins>;
270	pinctrl-names = "default";
271
272	status = "okay";
273};
274
275&scif_clk {
276	clock-frequency = <14745600>;
277};
278
279&sdhi0 {
280	pinctrl-0 = <&sdhi0_pins>;
281	pinctrl-names = "default";
282
283	vmmc-supply = <&vcc_sdhi0>;
284	cd-gpios = <&gpio3 6 GPIO_ACTIVE_LOW>;
285	status = "okay";
286};
287
288&cpu0 {
289	cpu0-supply = <&vdd_dvfs>;
290};
291
292&iic2	{
293	status = "okay";
294	pinctrl-0 = <&iic2_pins>;
295	pinctrl-names = "default";
296
297	clock-frequency = <100000>;
298
299	hdmi@39 {
300		compatible = "adi,adv7511w";
301		reg = <0x39>;
302		interrupts-extended = <&gpio1 15 IRQ_TYPE_LEVEL_LOW>;
303		clocks = <&osc4_clk>;
304		clock-names = "cec";
305
306		avdd-supply = <&fixedregulator1v8>;
307		dvdd-supply = <&fixedregulator1v8>;
308		pvdd-supply = <&fixedregulator1v8>;
309		dvdd-3v-supply = <&fixedregulator3v3>;
310		bgvdd-supply = <&fixedregulator1v8>;
311
312		adi,input-depth = <8>;
313		adi,input-colorspace = "rgb";
314		adi,input-clock = "1x";
315
316		ports {
317			#address-cells = <1>;
318			#size-cells = <0>;
319
320			port@0 {
321				reg = <0>;
322				adv7511_in: endpoint {
323					remote-endpoint = <&du_out_rgb>;
324				};
325			};
326
327			port@1 {
328				reg = <1>;
329				adv7511_out: endpoint {
330					remote-endpoint = <&hdmi_con_out>;
331				};
332			};
333		};
334	};
335};
336
337&iic3 {
338	pinctrl-names = "default";
339	pinctrl-0 = <&iic3_pins>, <&pmic_irq_pins>;
340	status = "okay";
341
342	pmic@58 {
343		compatible = "dlg,da9063";
344		reg = <0x58>;
345		interrupts-extended = <&irqc0 2 IRQ_TYPE_LEVEL_LOW>;
346		interrupt-controller;
347		#interrupt-cells = <2>;
348
349		onkey {
350			compatible = "dlg,da9063-onkey";
351		};
352
353		rtc {
354			compatible = "dlg,da9063-rtc";
355		};
356
357		watchdog {
358			compatible = "dlg,da9063-watchdog";
359		};
360	};
361
362	vdd_dvfs: regulator@68 {
363		compatible = "dlg,da9210";
364		reg = <0x68>;
365		interrupts-extended = <&irqc0 2 IRQ_TYPE_LEVEL_LOW>;
366
367		regulator-min-microvolt = <1000000>;
368		regulator-max-microvolt = <1000000>;
369		regulator-boot-on;
370		regulator-always-on;
371	};
372
373	vdd: regulator@70 {
374		compatible = "dlg,da9210";
375		reg = <0x70>;
376		interrupts-extended = <&irqc0 2 IRQ_TYPE_LEVEL_LOW>;
377
378		regulator-min-microvolt = <1000000>;
379		regulator-max-microvolt = <1000000>;
380		regulator-boot-on;
381		regulator-always-on;
382	};
383};
384
385&pci0 {
386	status = "okay";
387	pinctrl-0 = <&usb0_pins>;
388	pinctrl-names = "default";
389};
390
391&usbphy {
392	status = "okay";
393};
394