1/*
2 * Copyright (c) 2020-2021, Arm Limited. All rights reserved.
3 *
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7/dts-v1/;
8
9/ {
10	compatible = "arm,tc";
11	interrupt-parent = <&gic>;
12	#address-cells = <2>;
13	#size-cells = <2>;
14
15	aliases {
16		serial0 = &soc_uart0;
17	};
18
19	chosen {
20		stdout-path = "serial0:115200n8";
21	};
22
23	cpus {
24		#address-cells = <1>;
25		#size-cells = <0>;
26
27		cpu-map {
28			cluster0 {
29				core0 {
30					cpu = <&CPU0>;
31				};
32				core1 {
33					cpu = <&CPU1>;
34				};
35				core2 {
36					cpu = <&CPU2>;
37				};
38				core3 {
39					cpu = <&CPU3>;
40				};
41				core4 {
42					cpu = <&CPU4>;
43				};
44				core5 {
45					cpu = <&CPU5>;
46				};
47				core6 {
48					cpu = <&CPU6>;
49				};
50				core7 {
51					cpu = <&CPU7>;
52				};
53			};
54		};
55
56		/*
57		 * The timings below are just to demonstrate working cpuidle.
58		 * These values may be inaccurate.
59		 */
60		idle-states {
61			entry-method = "arm,psci";
62
63			CPU_SLEEP_0: cpu-sleep-0 {
64				compatible = "arm,idle-state";
65				arm,psci-suspend-param = <0x0010000>;
66				local-timer-stop;
67				entry-latency-us = <300>;
68				exit-latency-us = <1200>;
69				min-residency-us = <2000>;
70			};
71			CLUSTER_SLEEP_0: cluster-sleep-0 {
72				compatible = "arm,idle-state";
73				arm,psci-suspend-param = <0x1010000>;
74				local-timer-stop;
75				entry-latency-us = <400>;
76				exit-latency-us = <1200>;
77				min-residency-us = <2500>;
78			};
79		};
80
81		amus {
82			amu: amu-0 {
83				#address-cells = <1>;
84				#size-cells = <0>;
85
86				mpmm_gear0: counter@0 {
87					reg = <0>;
88
89					enable-at-el3;
90				};
91
92				mpmm_gear1: counter@1 {
93					reg = <1>;
94
95					enable-at-el3;
96				};
97
98				mpmm_gear2: counter@2 {
99					reg = <2>;
100
101					enable-at-el3;
102				};
103			};
104		};
105
106		CPU0:cpu@0 {
107			device_type = "cpu";
108			compatible = "arm,armv8";
109			reg = <0x0>;
110			enable-method = "psci";
111			clocks = <&scmi_dvfs 0>;
112			cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0>;
113			capacity-dmips-mhz = <406>;
114			amu = <&amu>;
115			supports-mpmm;
116		};
117
118		CPU1:cpu@100 {
119			device_type = "cpu";
120			compatible = "arm,armv8";
121			reg = <0x100>;
122			enable-method = "psci";
123			clocks = <&scmi_dvfs 0>;
124			cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0>;
125			capacity-dmips-mhz = <406>;
126			amu = <&amu>;
127			supports-mpmm;
128		};
129
130		CPU2:cpu@200 {
131			device_type = "cpu";
132			compatible = "arm,armv8";
133			reg = <0x200>;
134			enable-method = "psci";
135			clocks = <&scmi_dvfs 0>;
136			cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0>;
137			capacity-dmips-mhz = <406>;
138			amu = <&amu>;
139			supports-mpmm;
140		};
141
142		CPU3:cpu@300 {
143			device_type = "cpu";
144			compatible = "arm,armv8";
145			reg = <0x300>;
146			enable-method = "psci";
147			clocks = <&scmi_dvfs 0>;
148			cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0>;
149			capacity-dmips-mhz = <406>;
150			amu = <&amu>;
151			supports-mpmm;
152		};
153
154		CPU4:cpu@400 {
155			device_type = "cpu";
156			compatible = "arm,armv8";
157			reg = <0x400>;
158			enable-method = "psci";
159			clocks = <&scmi_dvfs 1>;
160			cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0>;
161			capacity-dmips-mhz = <912>;
162			amu = <&amu>;
163			supports-mpmm;
164		};
165
166		CPU5:cpu@500 {
167			device_type = "cpu";
168			compatible = "arm,armv8";
169			reg = <0x500>;
170			enable-method = "psci";
171			clocks = <&scmi_dvfs 1>;
172			cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0>;
173			capacity-dmips-mhz = <912>;
174			amu = <&amu>;
175			supports-mpmm;
176		};
177
178		CPU6:cpu@600 {
179			device_type = "cpu";
180			compatible = "arm,armv8";
181			reg = <0x600>;
182			enable-method = "psci";
183			clocks = <&scmi_dvfs 1>;
184			cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0>;
185			capacity-dmips-mhz = <912>;
186			amu = <&amu>;
187			supports-mpmm;
188		};
189
190		CPU7:cpu@700 {
191			device_type = "cpu";
192			compatible = "arm,armv8";
193			reg = <0x700>;
194			enable-method = "psci";
195			clocks = <&scmi_dvfs 2>;
196			cpu-idle-states = <&CPU_SLEEP_0 &CLUSTER_SLEEP_0>;
197			capacity-dmips-mhz = <1024>;
198			amu = <&amu>;
199			supports-mpmm;
200		};
201
202	};
203
204	reserved-memory {
205		#address-cells = <2>;
206		#size-cells = <2>;
207		ranges;
208
209		linux,cma {
210			compatible = "shared-dma-pool";
211			reusable;
212			size = <0x0 0x8000000>;
213			linux,cma-default;
214		};
215
216		optee@0xfce00000 {
217			reg = <0x00000000 0xfce00000 0 0x00200000>;
218			no-map;
219		};
220	};
221
222	psci {
223		compatible = "arm,psci-1.0", "arm,psci-0.2";
224		method = "smc";
225	};
226
227	sram: sram@6000000 {
228		compatible = "mmio-sram";
229		reg = <0x0 0x06000000 0x0 0x8000>;
230
231		#address-cells = <1>;
232		#size-cells = <1>;
233		ranges = <0 0x0 0x06000000 0x8000>;
234
235		cpu_scp_scmi_mem: scp-shmem@0 {
236			compatible = "arm,scmi-shmem";
237			reg = <0x0 0x80>;
238		};
239	};
240
241	mbox_db_rx: mhu@45010000 {
242		compatible = "arm,mhuv2-rx","arm,primecell";
243		reg = <0x0 0x45010000 0x0 0x1000>;
244		clocks = <&soc_refclk100mhz>;
245		clock-names = "apb_pclk";
246		#mbox-cells = <2>;
247		interrupts = <0 317 4>;
248		interrupt-names = "mhu_rx";
249		mhu-protocol = "doorbell";
250		arm,mhuv2-protocols = <0 1>;
251	};
252
253	mbox_db_tx: mhu@45000000 {
254		compatible = "arm,mhuv2-tx","arm,primecell";
255		reg = <0x0 0x45000000 0x0 0x1000>;
256		clocks = <&soc_refclk100mhz>;
257		clock-names = "apb_pclk";
258		#mbox-cells = <2>;
259		interrupt-names = "mhu_tx";
260		mhu-protocol = "doorbell";
261		arm,mhuv2-protocols = <0 1>;
262	};
263
264	cmn-pmu {
265		compatible = "arm,ci-700";
266		reg = <0x0 0x50000000 0x0 0x10000000>;
267		interrupts = <0x0 460 0x4>;
268	};
269
270	scmi {
271		compatible = "arm,scmi";
272		mbox-names = "tx", "rx";
273		mboxes = <&mbox_db_tx 0 0 &mbox_db_rx 0 0 >;
274		shmem = <&cpu_scp_scmi_mem &cpu_scp_scmi_mem>;
275		#address-cells = <1>;
276		#size-cells = <0>;
277
278		scmi_dvfs: protocol@13 {
279			reg = <0x13>;
280			#clock-cells = <1>;
281		};
282
283		scmi_clk: protocol@14 {
284			reg = <0x14>;
285			#clock-cells = <1>;
286		};
287	};
288
289	gic: interrupt-controller@2c010000 {
290		compatible = "arm,gic-600", "arm,gic-v3";
291		#address-cells = <2>;
292		#interrupt-cells = <3>;
293		#size-cells = <2>;
294		ranges;
295		interrupt-controller;
296		reg = <0x0 0x30000000 0 0x10000>, /* GICD */
297		      <0x0 0x30080000 0 0x200000>; /* GICR */
298		interrupts = <0x1 0x9 0x4>;
299	};
300
301	timer {
302		compatible = "arm,armv8-timer";
303		interrupts = <0x1 13 0x8>,
304			     <0x1 14 0x8>,
305			     <0x1 11 0x8>,
306			     <0x1 10 0x8>;
307	};
308
309	soc_refclk100mhz: refclk100mhz {
310		compatible = "fixed-clock";
311		#clock-cells = <0>;
312		clock-frequency = <100000000>;
313		clock-output-names = "apb_pclk";
314	};
315
316	soc_refclk60mhz: refclk60mhz {
317		compatible = "fixed-clock";
318		#clock-cells = <0>;
319		clock-frequency = <60000000>;
320		clock-output-names = "iofpga_clk";
321	};
322
323	soc_uartclk:  uartclk {
324		compatible = "fixed-clock";
325		#clock-cells = <0>;
326		clock-frequency = <50000000>;
327		clock-output-names = "uartclk";
328	};
329
330	soc_uart0: uart@7ff80000 {
331		compatible = "arm,pl011", "arm,primecell";
332		reg = <0x0 0x7ff80000 0x0 0x1000>;
333		interrupts = <0x0 116 0x4>;
334		clocks = <&soc_uartclk>, <&soc_refclk100mhz>;
335		clock-names = "uartclk", "apb_pclk";
336		status = "okay";
337	};
338
339	vencoder {
340		compatible = "drm,virtual-encoder";
341
342		port {
343			vencoder_in: endpoint {
344				remote-endpoint = <&dp_pl0_out0>;
345			};
346		};
347
348		display-timings {
349			panel-timing {
350				clock-frequency = <25175000>;
351				hactive = <640>;
352				vactive = <480>;
353				hfront-porch = <16>;
354				hback-porch = <48>;
355				hsync-len = <96>;
356				vfront-porch = <10>;
357				vback-porch = <33>;
358				vsync-len = <2>;
359			};
360		};
361
362	};
363
364	hdlcd: hdlcd@7ff60000 {
365		compatible = "arm,hdlcd";
366		reg = <0x0 0x7ff60000 0x0 0x1000>;
367		interrupts = <0x0 117 0x4>;
368		clocks = <&fake_hdlcd_clk>;
369		clock-names = "pxlclk";
370		status = "disabled";
371
372		port {
373			hdlcd_out: endpoint {
374				remote-endpoint = <&vencoder_in>;
375			};
376		};
377	};
378
379	fake_hdlcd_clk: fake-hdlcd-clk {
380		compatible = "fixed-clock";
381		#clock-cells = <0>;
382		clock-frequency = <25175000>;
383		clock-output-names = "pxlclk";
384	};
385
386	ethernet@18000000 {
387		compatible = "smsc,lan91c111";
388		reg = <0x0 0x18000000 0x0 0x10000>;
389		interrupts = <0 109 4>;
390	};
391
392	kmi@1c060000 {
393		compatible = "arm,pl050", "arm,primecell";
394		reg = <0x0 0x001c060000 0x0 0x1000>;
395		interrupts = <0 197 4>;
396		clocks = <&bp_clock24mhz>, <&bp_clock24mhz>;
397		clock-names = "KMIREFCLK", "apb_pclk";
398	};
399
400	kmi@1c070000 {
401		compatible = "arm,pl050", "arm,primecell";
402		reg = <0x0 0x001c070000 0x0 0x1000>;
403		interrupts = <0 103 4>;
404		clocks = <&bp_clock24mhz>, <&bp_clock24mhz>;
405		clock-names = "KMIREFCLK", "apb_pclk";
406	};
407
408	bp_clock24mhz: clock24mhz {
409		compatible = "fixed-clock";
410		#clock-cells = <0>;
411		clock-frequency = <24000000>;
412		clock-output-names = "bp:clock24mhz";
413	};
414
415	virtio_block@1c130000 {
416		compatible = "virtio,mmio";
417		reg = <0x0 0x1c130000 0x0 0x200>;
418		interrupts = <0 204 4>;
419	};
420
421	sysreg: sysreg@1c010000 {
422		compatible = "arm,vexpress-sysreg";
423		reg = <0x0 0x001c010000 0x0 0x1000>;
424		gpio-controller;
425		#gpio-cells = <2>;
426	};
427
428	fixed_3v3: v2m-3v3 {
429		compatible = "regulator-fixed";
430		regulator-name = "3V3";
431		regulator-min-microvolt = <3300000>;
432		regulator-max-microvolt = <3300000>;
433		regulator-always-on;
434	};
435
436	mmci@1c050000 {
437		compatible = "arm,pl180", "arm,primecell";
438		reg = <0x0 0x001c050000 0x0 0x1000>;
439		interrupts = <0 107 0x4>,
440			     <0 108 0x4>;
441		cd-gpios = <&sysreg 0 0>;
442		wp-gpios = <&sysreg 1 0>;
443		bus-width = <8>;
444		max-frequency = <12000000>;
445		vmmc-supply = <&fixed_3v3>;
446		clocks = <&bp_clock24mhz>, <&bp_clock24mhz>;
447		clock-names = "mclk", "apb_pclk";
448	};
449
450	gpu: gpu@2d000000 {
451		compatible = "arm,mali-midgard";
452		reg = <0x0 0x2d000000 0x0 0x200000>;
453		interrupts = <0 66 4>, <0 67 4>, <0 65 4>;
454		interrupt-names = "JOB", "MMU", "GPU";
455		clocks = <&soc_refclk100mhz>;
456		clock-names = "clk_mali";
457		operating-points = <
458			/* KHz uV */
459			50000 820000
460		>;
461	};
462
463	smmu: smmu@2ce00000 {
464		#iommu-cells = <1>;
465		compatible = "arm,smmu-v3";
466		reg = <0x0 0x2ce00000 0x0 0x20000>;
467		status = "okay";
468	};
469
470	dp0: display@2cc00000 {
471		#address-cells = <1>;
472		#size-cells = <0>;
473		compatible = "arm,mali-d71";
474		reg = <0 0x2cc00000 0 0x20000>;
475		interrupts = <0 69 4>;
476		interrupt-names = "DPU";
477		clocks = <&scmi_clk 0>;
478		clock-names = "aclk";
479		iommus = <&smmu 0>, <&smmu 1>, <&smmu 2>, <&smmu 3>,
480			<&smmu 4>, <&smmu 5>, <&smmu 6>, <&smmu 7>,
481			<&smmu 8>, <&smmu 9>;
482		pl0: pipeline@0 {
483			reg = <0>;
484			clocks = <&scmi_clk 1>;
485			clock-names = "pxclk";
486			pl_id = <0>;
487			ports {
488				#address-cells = <1>;
489				#size-cells = <0>;
490				port@0 {
491					reg = <0>;
492					dp_pl0_out0: endpoint {
493						remote-endpoint = <&vencoder_in>;
494					};
495				};
496			};
497		};
498
499		pl1: pipeline@1 {
500			reg = <1>;
501			clocks = <&scmi_clk 2>;
502			clock-names = "pxclk";
503			pl_id = <1>;
504			ports {
505				#address-cells = <1>;
506				#size-cells = <0>;
507				port@0 {
508					reg = <0>;
509				};
510			};
511		};
512	};
513
514	ete0 {
515		compatible = "arm,embedded-trace-extension";
516		cpu = <&CPU0>;
517	};
518
519	ete1 {
520		compatible = "arm,embedded-trace-extension";
521		cpu = <&CPU1>;
522	};
523
524	ete2 {
525		compatible = "arm,embedded-trace-extension";
526		cpu = <&CPU2>;
527	};
528
529	ete3 {
530		compatible = "arm,embedded-trace-extension";
531		cpu = <&CPU3>;
532	};
533
534	ete4 {
535		compatible = "arm,embedded-trace-extension";
536		cpu = <&CPU4>;
537	};
538
539	ete5 {
540		compatible = "arm,embedded-trace-extension";
541		cpu = <&CPU5>;
542	};
543
544	ete6 {
545		compatible = "arm,embedded-trace-extension";
546		cpu = <&CPU6>;
547	};
548
549	ete7 {
550		compatible = "arm,embedded-trace-extension";
551		cpu = <&CPU7>;
552	};
553
554	trbe0 {
555		compatible = "arm,trace-buffer-extension";
556		interrupts = <1 2 4>;
557	};
558};
559