1// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2/*
3 * Copyright 2019 NXP
4 */
5
6#include <dt-bindings/clock/imx8mn-clock.h>
7#include <dt-bindings/gpio/gpio.h>
8#include <dt-bindings/input/input.h>
9#include <dt-bindings/interrupt-controller/arm-gic.h>
10
11#include "imx8mn-pinfunc.h"
12
13/ {
14	interrupt-parent = <&gic>;
15	#address-cells = <2>;
16	#size-cells = <2>;
17
18	aliases {
19		ethernet0 = &fec1;
20		gpio0 = &gpio1;
21		gpio1 = &gpio2;
22		gpio2 = &gpio3;
23		gpio3 = &gpio4;
24		gpio4 = &gpio5;
25		i2c0 = &i2c1;
26		i2c1 = &i2c2;
27		i2c2 = &i2c3;
28		i2c3 = &i2c4;
29		mmc0 = &usdhc1;
30		mmc1 = &usdhc2;
31		mmc2 = &usdhc3;
32		serial0 = &uart1;
33		serial1 = &uart2;
34		serial2 = &uart3;
35		serial3 = &uart4;
36		spi0 = &ecspi1;
37		spi1 = &ecspi2;
38		spi2 = &ecspi3;
39	};
40
41	cpus {
42		#address-cells = <1>;
43		#size-cells = <0>;
44
45		idle-states {
46			entry-method = "psci";
47
48			cpu_pd_wait: cpu-pd-wait {
49				compatible = "arm,idle-state";
50				arm,psci-suspend-param = <0x0010033>;
51				local-timer-stop;
52				entry-latency-us = <1000>;
53				exit-latency-us = <700>;
54				min-residency-us = <2700>;
55			};
56		};
57
58		A53_0: cpu@0 {
59			device_type = "cpu";
60			compatible = "arm,cortex-a53";
61			reg = <0x0>;
62			clock-latency = <61036>;
63			clocks = <&clk IMX8MN_CLK_ARM>;
64			enable-method = "psci";
65			next-level-cache = <&A53_L2>;
66			operating-points-v2 = <&a53_opp_table>;
67			nvmem-cells = <&cpu_speed_grade>;
68			nvmem-cell-names = "speed_grade";
69			cpu-idle-states = <&cpu_pd_wait>;
70		};
71
72		A53_1: cpu@1 {
73			device_type = "cpu";
74			compatible = "arm,cortex-a53";
75			reg = <0x1>;
76			clock-latency = <61036>;
77			clocks = <&clk IMX8MN_CLK_ARM>;
78			enable-method = "psci";
79			next-level-cache = <&A53_L2>;
80			operating-points-v2 = <&a53_opp_table>;
81			cpu-idle-states = <&cpu_pd_wait>;
82		};
83
84		A53_2: cpu@2 {
85			device_type = "cpu";
86			compatible = "arm,cortex-a53";
87			reg = <0x2>;
88			clock-latency = <61036>;
89			clocks = <&clk IMX8MN_CLK_ARM>;
90			enable-method = "psci";
91			next-level-cache = <&A53_L2>;
92			operating-points-v2 = <&a53_opp_table>;
93			cpu-idle-states = <&cpu_pd_wait>;
94		};
95
96		A53_3: cpu@3 {
97			device_type = "cpu";
98			compatible = "arm,cortex-a53";
99			reg = <0x3>;
100			clock-latency = <61036>;
101			clocks = <&clk IMX8MN_CLK_ARM>;
102			enable-method = "psci";
103			next-level-cache = <&A53_L2>;
104			operating-points-v2 = <&a53_opp_table>;
105			cpu-idle-states = <&cpu_pd_wait>;
106		};
107
108		A53_L2: l2-cache0 {
109			compatible = "cache";
110		};
111	};
112
113	a53_opp_table: opp-table {
114		compatible = "operating-points-v2";
115		opp-shared;
116
117		opp-1200000000 {
118			opp-hz = /bits/ 64 <1200000000>;
119			opp-microvolt = <850000>;
120			opp-supported-hw = <0xb00>, <0x7>;
121			clock-latency-ns = <150000>;
122			opp-suspend;
123		};
124
125		opp-1400000000 {
126			opp-hz = /bits/ 64 <1400000000>;
127			opp-microvolt = <950000>;
128			opp-supported-hw = <0x300>, <0x7>;
129			clock-latency-ns = <150000>;
130			opp-suspend;
131		};
132
133		opp-1500000000 {
134			opp-hz = /bits/ 64 <1500000000>;
135			opp-microvolt = <1000000>;
136			opp-supported-hw = <0x100>, <0x3>;
137			clock-latency-ns = <150000>;
138			opp-suspend;
139		};
140	};
141
142	osc_32k: clock-osc-32k {
143		compatible = "fixed-clock";
144		#clock-cells = <0>;
145		clock-frequency = <32768>;
146		clock-output-names = "osc_32k";
147	};
148
149	osc_24m: clock-osc-24m {
150		compatible = "fixed-clock";
151		#clock-cells = <0>;
152		clock-frequency = <24000000>;
153		clock-output-names = "osc_24m";
154	};
155
156	clk_ext1: clock-ext1 {
157		compatible = "fixed-clock";
158		#clock-cells = <0>;
159		clock-frequency = <133000000>;
160		clock-output-names = "clk_ext1";
161	};
162
163	clk_ext2: clock-ext2 {
164		compatible = "fixed-clock";
165		#clock-cells = <0>;
166		clock-frequency = <133000000>;
167		clock-output-names = "clk_ext2";
168	};
169
170	clk_ext3: clock-ext3 {
171		compatible = "fixed-clock";
172		#clock-cells = <0>;
173		clock-frequency = <133000000>;
174		clock-output-names = "clk_ext3";
175	};
176
177	clk_ext4: clock-ext4 {
178		compatible = "fixed-clock";
179		#clock-cells = <0>;
180		clock-frequency= <133000000>;
181		clock-output-names = "clk_ext4";
182	};
183
184	psci {
185		compatible = "arm,psci-1.0";
186		method = "smc";
187	};
188
189	timer {
190		compatible = "arm,armv8-timer";
191		interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(6) | IRQ_TYPE_LEVEL_LOW)>,
192			     <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(6) | IRQ_TYPE_LEVEL_LOW)>,
193			     <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(6) | IRQ_TYPE_LEVEL_LOW)>,
194			     <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(6) | IRQ_TYPE_LEVEL_LOW)>;
195		clock-frequency = <8000000>;
196		arm,no-tick-in-suspend;
197	};
198
199	soc@0 {
200		compatible = "simple-bus";
201		#address-cells = <1>;
202		#size-cells = <1>;
203		ranges = <0x0 0x0 0x0 0x3e000000>;
204
205		aips1: bus@30000000 {
206			compatible = "simple-bus";
207			reg = <0x30000000 0x400000>;
208			#address-cells = <1>;
209			#size-cells = <1>;
210			ranges;
211
212			gpio1: gpio@30200000 {
213				compatible = "fsl,imx8mn-gpio", "fsl,imx35-gpio";
214				reg = <0x30200000 0x10000>;
215				interrupts = <GIC_SPI 64 IRQ_TYPE_LEVEL_HIGH>,
216					     <GIC_SPI 65 IRQ_TYPE_LEVEL_HIGH>;
217				clocks = <&clk IMX8MN_CLK_GPIO1_ROOT>;
218				gpio-controller;
219				#gpio-cells = <2>;
220				interrupt-controller;
221				#interrupt-cells = <2>;
222				gpio-ranges = <&iomuxc 0 10 30>;
223			};
224
225			gpio2: gpio@30210000 {
226				compatible = "fsl,imx8mn-gpio", "fsl,imx35-gpio";
227				reg = <0x30210000 0x10000>;
228				interrupts = <GIC_SPI 66 IRQ_TYPE_LEVEL_HIGH>,
229					     <GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>;
230				clocks = <&clk IMX8MN_CLK_GPIO2_ROOT>;
231				gpio-controller;
232				#gpio-cells = <2>;
233				interrupt-controller;
234				#interrupt-cells = <2>;
235				gpio-ranges = <&iomuxc 0 40 21>;
236			};
237
238			gpio3: gpio@30220000 {
239				compatible = "fsl,imx8mn-gpio", "fsl,imx35-gpio";
240				reg = <0x30220000 0x10000>;
241				interrupts = <GIC_SPI 68 IRQ_TYPE_LEVEL_HIGH>,
242					     <GIC_SPI 69 IRQ_TYPE_LEVEL_HIGH>;
243				clocks = <&clk IMX8MN_CLK_GPIO3_ROOT>;
244				gpio-controller;
245				#gpio-cells = <2>;
246				interrupt-controller;
247				#interrupt-cells = <2>;
248				gpio-ranges = <&iomuxc 0 61 26>;
249			};
250
251			gpio4: gpio@30230000 {
252				compatible = "fsl,imx8mn-gpio", "fsl,imx35-gpio";
253				reg = <0x30230000 0x10000>;
254				interrupts = <GIC_SPI 70 IRQ_TYPE_LEVEL_HIGH>,
255					     <GIC_SPI 71 IRQ_TYPE_LEVEL_HIGH>;
256				clocks = <&clk IMX8MN_CLK_GPIO4_ROOT>;
257				gpio-controller;
258				#gpio-cells = <2>;
259				interrupt-controller;
260				#interrupt-cells = <2>;
261				gpio-ranges = <&iomuxc 21 108 11>;
262			};
263
264			gpio5: gpio@30240000 {
265				compatible = "fsl,imx8mn-gpio", "fsl,imx35-gpio";
266				reg = <0x30240000 0x10000>;
267				interrupts = <GIC_SPI 72 IRQ_TYPE_LEVEL_HIGH>,
268					     <GIC_SPI 73 IRQ_TYPE_LEVEL_HIGH>;
269				clocks = <&clk IMX8MN_CLK_GPIO5_ROOT>;
270				gpio-controller;
271				#gpio-cells = <2>;
272				interrupt-controller;
273				#interrupt-cells = <2>;
274				gpio-ranges = <&iomuxc 0 119 30>;
275			};
276
277			wdog1: watchdog@30280000 {
278				compatible = "fsl,imx8mn-wdt", "fsl,imx21-wdt";
279				reg = <0x30280000 0x10000>;
280				interrupts = <GIC_SPI 78 IRQ_TYPE_LEVEL_HIGH>;
281				clocks = <&clk IMX8MN_CLK_WDOG1_ROOT>;
282				status = "disabled";
283			};
284
285			wdog2: watchdog@30290000 {
286				compatible = "fsl,imx8mn-wdt", "fsl,imx21-wdt";
287				reg = <0x30290000 0x10000>;
288				interrupts = <GIC_SPI 79 IRQ_TYPE_LEVEL_HIGH>;
289				clocks = <&clk IMX8MN_CLK_WDOG2_ROOT>;
290				status = "disabled";
291			};
292
293			wdog3: watchdog@302a0000 {
294				compatible = "fsl,imx8mn-wdt", "fsl,imx21-wdt";
295				reg = <0x302a0000 0x10000>;
296				interrupts = <GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>;
297				clocks = <&clk IMX8MN_CLK_WDOG3_ROOT>;
298				status = "disabled";
299			};
300
301			sdma3: dma-controller@302b0000 {
302				compatible = "fsl,imx8mn-sdma", "fsl,imx8mq-sdma";
303				reg = <0x302b0000 0x10000>;
304				interrupts = <GIC_SPI 34 IRQ_TYPE_LEVEL_HIGH>;
305				clocks = <&clk IMX8MN_CLK_SDMA3_ROOT>,
306				 <&clk IMX8MN_CLK_SDMA3_ROOT>;
307				clock-names = "ipg", "ahb";
308				#dma-cells = <3>;
309				fsl,sdma-ram-script-name = "imx/sdma/sdma-imx7d.bin";
310			};
311
312			sdma2: dma-controller@302c0000 {
313				compatible = "fsl,imx8mn-sdma", "fsl,imx8mq-sdma";
314				reg = <0x302c0000 0x10000>;
315				interrupts = <GIC_SPI 103 IRQ_TYPE_LEVEL_HIGH>;
316				clocks = <&clk IMX8MN_CLK_SDMA2_ROOT>,
317					 <&clk IMX8MN_CLK_SDMA2_ROOT>;
318				clock-names = "ipg", "ahb";
319				#dma-cells = <3>;
320				fsl,sdma-ram-script-name = "imx/sdma/sdma-imx7d.bin";
321			};
322
323			iomuxc: pinctrl@30330000 {
324				compatible = "fsl,imx8mn-iomuxc";
325				reg = <0x30330000 0x10000>;
326			};
327
328			gpr: iomuxc-gpr@30340000 {
329				compatible = "fsl,imx8mn-iomuxc-gpr", "syscon";
330				reg = <0x30340000 0x10000>;
331			};
332
333			ocotp: ocotp-ctrl@30350000 {
334				compatible = "fsl,imx8mn-ocotp", "fsl,imx8mm-ocotp", "syscon";
335				reg = <0x30350000 0x10000>;
336				clocks = <&clk IMX8MN_CLK_OCOTP_ROOT>;
337				#address-cells = <1>;
338				#size-cells = <1>;
339
340				cpu_speed_grade: speed-grade@10 {
341					reg = <0x10 4>;
342				};
343			};
344
345			anatop: anatop@30360000 {
346				compatible = "fsl,imx8mn-anatop", "fsl,imx8mm-anatop",
347					     "syscon";
348				reg = <0x30360000 0x10000>;
349			};
350
351			snvs: snvs@30370000 {
352				compatible = "fsl,sec-v4.0-mon","syscon", "simple-mfd";
353				reg = <0x30370000 0x10000>;
354
355				snvs_rtc: snvs-rtc-lp {
356					compatible = "fsl,sec-v4.0-mon-rtc-lp";
357					regmap = <&snvs>;
358					offset = <0x34>;
359					interrupts = <GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>,
360						     <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>;
361					clock-names = "snvs-rtc";
362				};
363
364				snvs_pwrkey: snvs-powerkey {
365					compatible = "fsl,sec-v4.0-pwrkey";
366					regmap = <&snvs>;
367					interrupts = <GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>;
368					linux,keycode = <KEY_POWER>;
369					wakeup-source;
370					status = "disabled";
371				};
372			};
373
374			clk: clock-controller@30380000 {
375				compatible = "fsl,imx8mn-ccm";
376				reg = <0x30380000 0x10000>;
377				#clock-cells = <1>;
378				clocks = <&osc_32k>, <&osc_24m>, <&clk_ext1>, <&clk_ext2>,
379					 <&clk_ext3>, <&clk_ext4>;
380				clock-names = "osc_32k", "osc_24m", "clk_ext1", "clk_ext2",
381					      "clk_ext3", "clk_ext4";
382			};
383
384			src: reset-controller@30390000 {
385				compatible = "fsl,imx8mn-src", "fsl,imx8mq-src", "syscon";
386				reg = <0x30390000 0x10000>;
387				interrupts = <GIC_SPI 89 IRQ_TYPE_LEVEL_HIGH>;
388				#reset-cells = <1>;
389			};
390		};
391
392		aips2: bus@30400000 {
393			compatible = "simple-bus";
394			reg = <0x30400000 0x400000>;
395			#address-cells = <1>;
396			#size-cells = <1>;
397			ranges;
398
399			pwm1: pwm@30660000 {
400				compatible = "fsl,imx8mn-pwm", "fsl,imx27-pwm";
401				reg = <0x30660000 0x10000>;
402				interrupts = <GIC_SPI 81 IRQ_TYPE_LEVEL_HIGH>;
403				clocks = <&clk IMX8MN_CLK_PWM1_ROOT>,
404					<&clk IMX8MN_CLK_PWM1_ROOT>;
405				clock-names = "ipg", "per";
406				#pwm-cells = <2>;
407				status = "disabled";
408			};
409
410			pwm2: pwm@30670000 {
411				compatible = "fsl,imx8mn-pwm", "fsl,imx27-pwm";
412				reg = <0x30670000 0x10000>;
413				interrupts = <GIC_SPI 82 IRQ_TYPE_LEVEL_HIGH>;
414				clocks = <&clk IMX8MN_CLK_PWM2_ROOT>,
415					 <&clk IMX8MN_CLK_PWM2_ROOT>;
416				clock-names = "ipg", "per";
417				#pwm-cells = <2>;
418				status = "disabled";
419			};
420
421			pwm3: pwm@30680000 {
422				compatible = "fsl,imx8mn-pwm", "fsl,imx27-pwm";
423				reg = <0x30680000 0x10000>;
424				interrupts = <GIC_SPI 83 IRQ_TYPE_LEVEL_HIGH>;
425				clocks = <&clk IMX8MN_CLK_PWM3_ROOT>,
426					 <&clk IMX8MN_CLK_PWM3_ROOT>;
427				clock-names = "ipg", "per";
428				#pwm-cells = <2>;
429				status = "disabled";
430			};
431
432			pwm4: pwm@30690000 {
433				compatible = "fsl,imx8mn-pwm", "fsl,imx27-pwm";
434				reg = <0x30690000 0x10000>;
435				interrupts = <GIC_SPI 84 IRQ_TYPE_LEVEL_HIGH>;
436				clocks = <&clk IMX8MN_CLK_PWM4_ROOT>,
437					 <&clk IMX8MN_CLK_PWM4_ROOT>;
438				clock-names = "ipg", "per";
439				#pwm-cells = <2>;
440				status = "disabled";
441			};
442
443			system_counter: timer@306a0000 {
444				compatible = "nxp,sysctr-timer";
445				reg = <0x306a0000 0x20000>;
446				interrupts = <GIC_SPI 47 IRQ_TYPE_LEVEL_HIGH>;
447				clocks = <&osc_24m>;
448				clock-names = "per";
449			};
450		};
451
452		aips3: bus@30800000 {
453			compatible = "simple-bus";
454			reg = <0x30800000 0x400000>;
455			#address-cells = <1>;
456			#size-cells = <1>;
457			ranges;
458
459			ecspi1: spi@30820000 {
460				compatible = "fsl,imx8mn-ecspi", "fsl,imx51-ecspi";
461				#address-cells = <1>;
462				#size-cells = <0>;
463				reg = <0x30820000 0x10000>;
464				interrupts = <GIC_SPI 31 IRQ_TYPE_LEVEL_HIGH>;
465				clocks = <&clk IMX8MN_CLK_ECSPI1_ROOT>,
466					 <&clk IMX8MN_CLK_ECSPI1_ROOT>;
467				clock-names = "ipg", "per";
468				dmas = <&sdma1 0 7 1>, <&sdma1 1 7 2>;
469				dma-names = "rx", "tx";
470				status = "disabled";
471			};
472
473			ecspi2: spi@30830000 {
474				compatible = "fsl,imx8mn-ecspi", "fsl,imx51-ecspi";
475				#address-cells = <1>;
476				#size-cells = <0>;
477				reg = <0x30830000 0x10000>;
478				interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_HIGH>;
479				clocks = <&clk IMX8MN_CLK_ECSPI2_ROOT>,
480					 <&clk IMX8MN_CLK_ECSPI2_ROOT>;
481				clock-names = "ipg", "per";
482				dmas = <&sdma1 2 7 1>, <&sdma1 3 7 2>;
483				dma-names = "rx", "tx";
484				status = "disabled";
485			};
486
487			ecspi3: spi@30840000 {
488				compatible = "fsl,imx8mn-ecspi", "fsl,imx51-ecspi";
489				#address-cells = <1>;
490				#size-cells = <0>;
491				reg = <0x30840000 0x10000>;
492				interrupts = <GIC_SPI 33 IRQ_TYPE_LEVEL_HIGH>;
493				clocks = <&clk IMX8MN_CLK_ECSPI3_ROOT>,
494					 <&clk IMX8MN_CLK_ECSPI3_ROOT>;
495				clock-names = "ipg", "per";
496				dmas = <&sdma1 4 7 1>, <&sdma1 5 7 2>;
497				dma-names = "rx", "tx";
498				status = "disabled";
499			};
500
501			uart1: serial@30860000 {
502				compatible = "fsl,imx8mn-uart", "fsl,imx6q-uart";
503				reg = <0x30860000 0x10000>;
504				interrupts = <GIC_SPI 26 IRQ_TYPE_LEVEL_HIGH>;
505				clocks = <&clk IMX8MN_CLK_UART1_ROOT>,
506					 <&clk IMX8MN_CLK_UART1_ROOT>;
507				clock-names = "ipg", "per";
508				dmas = <&sdma1 22 4 0>, <&sdma1 23 4 0>;
509				dma-names = "rx", "tx";
510				status = "disabled";
511			};
512
513			uart3: serial@30880000 {
514				compatible = "fsl,imx8mn-uart", "fsl,imx6q-uart";
515				reg = <0x30880000 0x10000>;
516				interrupts = <GIC_SPI 28 IRQ_TYPE_LEVEL_HIGH>;
517				clocks = <&clk IMX8MN_CLK_UART3_ROOT>,
518					 <&clk IMX8MN_CLK_UART3_ROOT>;
519				clock-names = "ipg", "per";
520				dmas = <&sdma1 26 4 0>, <&sdma1 27 4 0>;
521				dma-names = "rx", "tx";
522				status = "disabled";
523			};
524
525			uart2: serial@30890000 {
526				compatible = "fsl,imx8mn-uart", "fsl,imx6q-uart";
527				reg = <0x30890000 0x10000>;
528				interrupts = <GIC_SPI 27 IRQ_TYPE_LEVEL_HIGH>;
529				clocks = <&clk IMX8MN_CLK_UART2_ROOT>,
530					 <&clk IMX8MN_CLK_UART2_ROOT>;
531				clock-names = "ipg", "per";
532				status = "disabled";
533			};
534
535			crypto: crypto@30900000 {
536				compatible = "fsl,sec-v4.0";
537				#address-cells = <1>;
538				#size-cells = <1>;
539				reg = <0x30900000 0x40000>;
540				ranges = <0 0x30900000 0x40000>;
541				interrupts = <GIC_SPI 91 IRQ_TYPE_LEVEL_HIGH>;
542				clocks = <&clk IMX8MN_CLK_AHB>,
543					 <&clk IMX8MN_CLK_IPG_ROOT>;
544				clock-names = "aclk", "ipg";
545
546				sec_jr0: jr0@1000 {
547					 compatible = "fsl,sec-v4.0-job-ring";
548					 reg = <0x1000 0x1000>;
549					 interrupts = <GIC_SPI 105 IRQ_TYPE_LEVEL_HIGH>;
550				};
551
552				sec_jr1: jr1@2000 {
553					 compatible = "fsl,sec-v4.0-job-ring";
554					 reg = <0x2000 0x1000>;
555					 interrupts = <GIC_SPI 106 IRQ_TYPE_LEVEL_HIGH>;
556				};
557
558				sec_jr2: jr2@3000 {
559					 compatible = "fsl,sec-v4.0-job-ring";
560					 reg = <0x3000 0x1000>;
561					 interrupts = <GIC_SPI 114 IRQ_TYPE_LEVEL_HIGH>;
562				};
563			};
564
565			i2c1: i2c@30a20000 {
566				compatible = "fsl,imx8mn-i2c", "fsl,imx21-i2c";
567				#address-cells = <1>;
568				#size-cells = <0>;
569				reg = <0x30a20000 0x10000>;
570				interrupts = <GIC_SPI 35 IRQ_TYPE_LEVEL_HIGH>;
571				clocks = <&clk IMX8MN_CLK_I2C1_ROOT>;
572				status = "disabled";
573			};
574
575			i2c2: i2c@30a30000 {
576				compatible = "fsl,imx8mn-i2c", "fsl,imx21-i2c";
577				#address-cells = <1>;
578				#size-cells = <0>;
579				reg = <0x30a30000 0x10000>;
580				interrupts = <GIC_SPI 36 IRQ_TYPE_LEVEL_HIGH>;
581				clocks = <&clk IMX8MN_CLK_I2C2_ROOT>;
582				status = "disabled";
583			};
584
585			i2c3: i2c@30a40000 {
586				#address-cells = <1>;
587				#size-cells = <0>;
588				compatible = "fsl,imx8mn-i2c", "fsl,imx21-i2c";
589				reg = <0x30a40000 0x10000>;
590				interrupts = <GIC_SPI 37 IRQ_TYPE_LEVEL_HIGH>;
591				clocks = <&clk IMX8MN_CLK_I2C3_ROOT>;
592				status = "disabled";
593			};
594
595			i2c4: i2c@30a50000 {
596				compatible = "fsl,imx8mn-i2c", "fsl,imx21-i2c";
597				#address-cells = <1>;
598				#size-cells = <0>;
599				reg = <0x30a50000 0x10000>;
600				interrupts = <GIC_SPI 38 IRQ_TYPE_LEVEL_HIGH>;
601				clocks = <&clk IMX8MN_CLK_I2C4_ROOT>;
602				status = "disabled";
603			};
604
605			uart4: serial@30a60000 {
606				compatible = "fsl,imx8mn-uart", "fsl,imx6q-uart";
607				reg = <0x30a60000 0x10000>;
608				interrupts = <GIC_SPI 29 IRQ_TYPE_LEVEL_HIGH>;
609				clocks = <&clk IMX8MN_CLK_UART4_ROOT>,
610					 <&clk IMX8MN_CLK_UART4_ROOT>;
611				clock-names = "ipg", "per";
612				dmas = <&sdma1 28 4 0>, <&sdma1 29 4 0>;
613				dma-names = "rx", "tx";
614				status = "disabled";
615			};
616
617			usdhc1: mmc@30b40000 {
618				compatible = "fsl,imx8mn-usdhc", "fsl,imx7d-usdhc";
619				reg = <0x30b40000 0x10000>;
620				interrupts = <GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH>;
621				clocks = <&clk IMX8MN_CLK_IPG_ROOT>,
622					 <&clk IMX8MN_CLK_NAND_USDHC_BUS>,
623					 <&clk IMX8MN_CLK_USDHC1_ROOT>;
624				clock-names = "ipg", "ahb", "per";
625				fsl,tuning-start-tap = <20>;
626				fsl,tuning-step= <2>;
627				bus-width = <4>;
628				status = "disabled";
629			};
630
631			usdhc2: mmc@30b50000 {
632				compatible = "fsl,imx8mn-usdhc", "fsl,imx7d-usdhc";
633				reg = <0x30b50000 0x10000>;
634				interrupts = <GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH>;
635				clocks = <&clk IMX8MN_CLK_IPG_ROOT>,
636					 <&clk IMX8MN_CLK_NAND_USDHC_BUS>,
637					 <&clk IMX8MN_CLK_USDHC2_ROOT>;
638				clock-names = "ipg", "ahb", "per";
639				fsl,tuning-start-tap = <20>;
640				fsl,tuning-step= <2>;
641				bus-width = <4>;
642				status = "disabled";
643			};
644
645			usdhc3: mmc@30b60000 {
646				compatible = "fsl,imx8mn-usdhc", "fsl,imx7d-usdhc";
647				reg = <0x30b60000 0x10000>;
648				interrupts = <GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>;
649				clocks = <&clk IMX8MN_CLK_IPG_ROOT>,
650					 <&clk IMX8MN_CLK_NAND_USDHC_BUS>,
651					 <&clk IMX8MN_CLK_USDHC3_ROOT>;
652				clock-names = "ipg", "ahb", "per";
653				fsl,tuning-start-tap = <20>;
654				fsl,tuning-step= <2>;
655				bus-width = <4>;
656				status = "disabled";
657			};
658
659			sdma1: dma-controller@30bd0000 {
660				compatible = "fsl,imx8mn-sdma", "fsl,imx8mq-sdma";
661				reg = <0x30bd0000 0x10000>;
662				interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
663				clocks = <&clk IMX8MN_CLK_SDMA1_ROOT>,
664					 <&clk IMX8MN_CLK_SDMA1_ROOT>;
665				clock-names = "ipg", "ahb";
666				#dma-cells = <3>;
667				fsl,sdma-ram-script-name = "imx/sdma/sdma-imx7d.bin";
668			};
669
670			fec1: ethernet@30be0000 {
671				compatible = "fsl,imx8mn-fec", "fsl,imx6sx-fec";
672				reg = <0x30be0000 0x10000>;
673				interrupts = <GIC_SPI 118 IRQ_TYPE_LEVEL_HIGH>,
674					     <GIC_SPI 119 IRQ_TYPE_LEVEL_HIGH>,
675					     <GIC_SPI 120 IRQ_TYPE_LEVEL_HIGH>;
676				clocks = <&clk IMX8MN_CLK_ENET1_ROOT>,
677					 <&clk IMX8MN_CLK_ENET1_ROOT>,
678					 <&clk IMX8MN_CLK_ENET_TIMER>,
679					 <&clk IMX8MN_CLK_ENET_REF>,
680					 <&clk IMX8MN_CLK_ENET_PHY_REF>;
681				clock-names = "ipg", "ahb", "ptp",
682					      "enet_clk_ref", "enet_out";
683				assigned-clocks = <&clk IMX8MN_CLK_ENET_AXI>,
684						  <&clk IMX8MN_CLK_ENET_TIMER>,
685						  <&clk IMX8MN_CLK_ENET_REF>,
686						  <&clk IMX8MN_CLK_ENET_TIMER>;
687				assigned-clock-parents = <&clk IMX8MN_SYS_PLL1_266M>,
688							 <&clk IMX8MN_SYS_PLL2_100M>,
689							 <&clk IMX8MN_SYS_PLL2_125M>;
690				assigned-clock-rates = <0>, <0>, <125000000>, <100000000>;
691				fsl,num-tx-queues = <3>;
692				fsl,num-rx-queues = <3>;
693				status = "disabled";
694			};
695
696		};
697
698		aips4: bus@32c00000 {
699			compatible = "simple-bus";
700			reg = <0x32c00000 0x400000>;
701			#address-cells = <1>;
702			#size-cells = <1>;
703			ranges;
704
705			usbotg1: usb@32e40000 {
706				compatible = "fsl,imx8mn-usb", "fsl,imx7d-usb";
707				reg = <0x32e40000 0x200>;
708				interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>;
709				clocks = <&clk IMX8MN_CLK_USB1_CTRL_ROOT>;
710				clock-names = "usb1_ctrl_root_clk";
711				assigned-clocks = <&clk IMX8MN_CLK_USB_BUS>;
712				assigned-clock-parents = <&clk IMX8MN_SYS_PLL2_500M>;
713				fsl,usbphy = <&usbphynop1>;
714				fsl,usbmisc = <&usbmisc1 0>;
715				status = "disabled";
716			};
717
718			usbmisc1: usbmisc@32e40200 {
719				compatible = "fsl,imx8mn-usbmisc", "fsl,imx7d-usbmisc";
720				#index-cells = <1>;
721				reg = <0x32e40200 0x200>;
722			};
723
724			usbotg2: usb@32e50000 {
725				compatible = "fsl,imx8mn-usb", "fsl,imx7d-usb";
726				reg = <0x32e50000 0x200>;
727				interrupts = <GIC_SPI 41 IRQ_TYPE_LEVEL_HIGH>;
728				clocks = <&clk IMX8MN_CLK_USB1_CTRL_ROOT>;
729				clock-names = "usb1_ctrl_root_clk";
730				assigned-clocks = <&clk IMX8MN_CLK_USB_BUS>,
731						  <&clk IMX8MN_CLK_USB_CORE_REF>;
732				assigned-clock-parents = <&clk IMX8MN_SYS_PLL2_500M>,
733							 <&clk IMX8MN_SYS_PLL1_100M>;
734				fsl,usbphy = <&usbphynop2>;
735				fsl,usbmisc = <&usbmisc2 0>;
736				status = "disabled";
737			};
738
739			usbmisc2: usbmisc@32e50200 {
740				compatible = "fsl,imx8mn-usbmisc", "fsl,imx7d-usbmisc";
741				#index-cells = <1>;
742				reg = <0x32e50200 0x200>;
743			};
744
745		};
746
747		dma_apbh: dma-controller@33000000 {
748			compatible = "fsl,imx7d-dma-apbh", "fsl,imx28-dma-apbh";
749			reg = <0x33000000 0x2000>;
750			interrupts = <GIC_SPI 12 IRQ_TYPE_LEVEL_HIGH>,
751				     <GIC_SPI 12 IRQ_TYPE_LEVEL_HIGH>,
752				     <GIC_SPI 12 IRQ_TYPE_LEVEL_HIGH>,
753				     <GIC_SPI 12 IRQ_TYPE_LEVEL_HIGH>;
754			interrupt-names = "gpmi0", "gpmi1", "gpmi2", "gpmi3";
755			#dma-cells = <1>;
756			dma-channels = <4>;
757			clocks = <&clk IMX8MN_CLK_NAND_USDHC_BUS_RAWNAND_CLK>;
758		};
759
760		gpmi: nand-controller@33002000 {
761			compatible = "fsl,imx8mn-gpmi-nand", "fsl,imx7d-gpmi-nand";
762			#address-cells = <1>;
763			#size-cells = <1>;
764			reg = <0x33002000 0x2000>, <0x33004000 0x4000>;
765			reg-names = "gpmi-nand", "bch";
766			interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>;
767			interrupt-names = "bch";
768			clocks = <&clk IMX8MN_CLK_NAND_ROOT>,
769				 <&clk IMX8MN_CLK_NAND_USDHC_BUS_RAWNAND_CLK>;
770			clock-names = "gpmi_io", "gpmi_bch_apb";
771			dmas = <&dma_apbh 0>;
772			dma-names = "rx-tx";
773			status = "disabled";
774		};
775
776		gic: interrupt-controller@38800000 {
777			compatible = "arm,gic-v3";
778			reg = <0x38800000 0x10000>,
779			      <0x38880000 0xc0000>;
780			#interrupt-cells = <3>;
781			interrupt-controller;
782			interrupts = <GIC_PPI 9 IRQ_TYPE_LEVEL_HIGH>;
783		};
784
785		ddrc: memory-controller@3d400000 {
786			compatible = "fsl,imx8mn-ddrc", "fsl,imx8m-ddrc";
787			reg = <0x3d400000 0x400000>;
788			clock-names = "core", "pll", "alt", "apb";
789			clocks = <&clk IMX8MN_CLK_DRAM_CORE>,
790				 <&clk IMX8MN_DRAM_PLL>,
791				 <&clk IMX8MN_CLK_DRAM_ALT>,
792				 <&clk IMX8MN_CLK_DRAM_APB>;
793		};
794
795		ddr-pmu@3d800000 {
796			compatible = "fsl,imx8mn-ddr-pmu", "fsl,imx8m-ddr-pmu";
797			reg = <0x3d800000 0x400000>;
798			interrupts = <GIC_SPI 98 IRQ_TYPE_LEVEL_HIGH>;
799		};
800	};
801
802	usbphynop1: usbphynop1 {
803		compatible = "usb-nop-xceiv";
804		clocks = <&clk IMX8MN_CLK_USB_PHY_REF>;
805		assigned-clocks = <&clk IMX8MN_CLK_USB_PHY_REF>;
806		assigned-clock-parents = <&clk IMX8MN_SYS_PLL1_100M>;
807		clock-names = "main_clk";
808	};
809
810	usbphynop2: usbphynop2 {
811		compatible = "usb-nop-xceiv";
812		clocks = <&clk IMX8MN_CLK_USB_PHY_REF>;
813		assigned-clocks = <&clk IMX8MN_CLK_USB_PHY_REF>;
814		assigned-clock-parents = <&clk IMX8MN_SYS_PLL1_100M>;
815		clock-names = "main_clk";
816	};
817};
818