1// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2/*
3 * Copyright (c) 2017 Amlogic, Inc. All rights reserved.
4 */
5
6#include <dt-bindings/gpio/gpio.h>
7#include <dt-bindings/interrupt-controller/irq.h>
8#include <dt-bindings/interrupt-controller/arm-gic.h>
9#include <dt-bindings/clock/axg-clkc.h>
10#include <dt-bindings/clock/axg-aoclkc.h>
11#include <dt-bindings/gpio/meson-axg-gpio.h>
12#include <dt-bindings/reset/amlogic,meson-axg-reset.h>
13
14/ {
15	compatible = "amlogic,meson-axg";
16
17	interrupt-parent = <&gic>;
18	#address-cells = <2>;
19	#size-cells = <2>;
20
21	reserved-memory {
22		#address-cells = <2>;
23		#size-cells = <2>;
24		ranges;
25
26		/* 16 MiB reserved for Hardware ROM Firmware */
27		hwrom_reserved: hwrom@0 {
28			reg = <0x0 0x0 0x0 0x1000000>;
29			no-map;
30		};
31
32		/* Alternate 3 MiB reserved for ARM Trusted Firmware (BL31) */
33		secmon_reserved: secmon@5000000 {
34			reg = <0x0 0x05000000 0x0 0x300000>;
35			no-map;
36		};
37	};
38
39	cpus {
40		#address-cells = <0x2>;
41		#size-cells = <0x0>;
42
43		cpu0: cpu@0 {
44			device_type = "cpu";
45			compatible = "arm,cortex-a53", "arm,armv8";
46			reg = <0x0 0x0>;
47			enable-method = "psci";
48			next-level-cache = <&l2>;
49		};
50
51		cpu1: cpu@1 {
52			device_type = "cpu";
53			compatible = "arm,cortex-a53", "arm,armv8";
54			reg = <0x0 0x1>;
55			enable-method = "psci";
56			next-level-cache = <&l2>;
57		};
58
59		cpu2: cpu@2 {
60			device_type = "cpu";
61			compatible = "arm,cortex-a53", "arm,armv8";
62			reg = <0x0 0x2>;
63			enable-method = "psci";
64			next-level-cache = <&l2>;
65		};
66
67		cpu3: cpu@3 {
68			device_type = "cpu";
69			compatible = "arm,cortex-a53", "arm,armv8";
70			reg = <0x0 0x3>;
71			enable-method = "psci";
72			next-level-cache = <&l2>;
73		};
74
75		l2: l2-cache0 {
76			compatible = "cache";
77		};
78	};
79
80	arm-pmu {
81		compatible = "arm,cortex-a53-pmu";
82		interrupts = <GIC_SPI 137 IRQ_TYPE_LEVEL_HIGH>,
83			     <GIC_SPI 138 IRQ_TYPE_LEVEL_HIGH>,
84			     <GIC_SPI 153 IRQ_TYPE_LEVEL_HIGH>,
85			     <GIC_SPI 154 IRQ_TYPE_LEVEL_HIGH>;
86		interrupt-affinity = <&cpu0>, <&cpu1>, <&cpu2>, <&cpu3>;
87	};
88
89	psci {
90		compatible = "arm,psci-1.0";
91		method = "smc";
92	};
93
94	timer {
95		compatible = "arm,armv8-timer";
96		interrupts = <GIC_PPI 13
97			(GIC_CPU_MASK_RAW(0xff) | IRQ_TYPE_LEVEL_LOW)>,
98			     <GIC_PPI 14
99			(GIC_CPU_MASK_RAW(0xff) | IRQ_TYPE_LEVEL_LOW)>,
100			     <GIC_PPI 11
101			(GIC_CPU_MASK_RAW(0xff) | IRQ_TYPE_LEVEL_LOW)>,
102			     <GIC_PPI 10
103			(GIC_CPU_MASK_RAW(0xff) | IRQ_TYPE_LEVEL_LOW)>;
104	};
105
106	xtal: xtal-clk {
107		compatible = "fixed-clock";
108		clock-frequency = <24000000>;
109		clock-output-names = "xtal";
110		#clock-cells = <0>;
111	};
112
113	ao_alt_xtal: ao_alt_xtal-clk {
114		compatible = "fixed-clock";
115		clock-frequency = <32000000>;
116		clock-output-names = "ao_alt_xtal";
117		#clock-cells = <0>;
118	};
119
120	soc {
121		compatible = "simple-bus";
122		#address-cells = <2>;
123		#size-cells = <2>;
124		ranges;
125
126		apb: apb@ffe00000 {
127			compatible = "simple-bus";
128			reg = <0x0 0xffe00000 0x0 0x200000>;
129			#address-cells = <2>;
130			#size-cells = <2>;
131			ranges = <0x0 0x0 0x0 0xffe00000 0x0 0x200000>;
132
133			sd_emmc_b: sd@5000 {
134				compatible = "amlogic,meson-axg-mmc";
135				reg = <0x0 0x5000 0x0 0x2000>;
136				interrupts = <GIC_SPI 217 IRQ_TYPE_EDGE_RISING>;
137				status = "disabled";
138				clocks = <&clkc CLKID_SD_EMMC_B>,
139					<&clkc CLKID_SD_EMMC_B_CLK0>,
140					<&clkc CLKID_FCLK_DIV2>;
141				clock-names = "core", "clkin0", "clkin1";
142				resets = <&reset RESET_SD_EMMC_B>;
143			};
144
145			sd_emmc_c: mmc@7000 {
146				compatible = "amlogic,meson-axg-mmc";
147				reg = <0x0 0x7000 0x0 0x2000>;
148				interrupts = <GIC_SPI 218 IRQ_TYPE_EDGE_RISING>;
149				status = "disabled";
150				clocks = <&clkc CLKID_SD_EMMC_C>,
151					<&clkc CLKID_SD_EMMC_C_CLK0>,
152					<&clkc CLKID_FCLK_DIV2>;
153				clock-names = "core", "clkin0", "clkin1";
154				resets = <&reset RESET_SD_EMMC_C>;
155			};
156		};
157
158		cbus: bus@ffd00000 {
159			compatible = "simple-bus";
160			reg = <0x0 0xffd00000 0x0 0x25000>;
161			#address-cells = <2>;
162			#size-cells = <2>;
163			ranges = <0x0 0x0 0x0 0xffd00000 0x0 0x25000>;
164
165			gpio_intc: interrupt-controller@f080 {
166				compatible = "amlogic,meson-gpio-intc";
167				reg = <0x0 0xf080 0x0 0x10>;
168				interrupt-controller;
169				#interrupt-cells = <2>;
170				amlogic,channel-interrupts = <64 65 66 67 68 69 70 71>;
171				status = "disabled";
172			};
173
174			pwm_ab: pwm@1b000 {
175				compatible = "amlogic,meson-axg-ee-pwm";
176				reg = <0x0 0x1b000 0x0 0x20>;
177				#pwm-cells = <3>;
178				status = "disabled";
179			};
180
181			pwm_cd: pwm@1a000 {
182				compatible = "amlogic,meson-axg-ee-pwm";
183				reg = <0x0 0x1a000 0x0 0x20>;
184				#pwm-cells = <3>;
185				status = "disabled";
186			};
187
188			reset: reset-controller@1004 {
189				compatible = "amlogic,meson-axg-reset";
190				reg = <0x0 0x01004 0x0 0x9c>;
191				#reset-cells = <1>;
192			};
193
194			spicc0: spi@13000 {
195				compatible = "amlogic,meson-axg-spicc";
196				reg = <0x0 0x13000 0x0 0x3c>;
197				interrupts = <GIC_SPI 81 IRQ_TYPE_LEVEL_HIGH>;
198				clocks = <&clkc CLKID_SPICC0>;
199				clock-names = "core";
200				#address-cells = <1>;
201				#size-cells = <0>;
202				status = "disabled";
203			};
204
205			spicc1: spi@15000 {
206				compatible = "amlogic,meson-axg-spicc";
207				reg = <0x0 0x15000 0x0 0x3c>;
208				interrupts = <GIC_SPI 82 IRQ_TYPE_LEVEL_HIGH>;
209				clocks = <&clkc CLKID_SPICC1>;
210				clock-names = "core";
211				#address-cells = <1>;
212				#size-cells = <0>;
213				status = "disabled";
214			};
215
216			i2c0: i2c@1f000 {
217				compatible = "amlogic,meson-axg-i2c";
218				reg = <0x0 0x1f000 0x0 0x20>;
219				interrupts = <GIC_SPI 21 IRQ_TYPE_EDGE_RISING>;
220				clocks = <&clkc CLKID_I2C>;
221				#address-cells = <1>;
222				#size-cells = <0>;
223				status = "disabled";
224			};
225
226			i2c1: i2c@1e000 {
227				compatible = "amlogic,meson-axg-i2c";
228				reg = <0x0 0x1e000 0x0 0x20>;
229				interrupts = <GIC_SPI 214 IRQ_TYPE_EDGE_RISING>;
230				clocks = <&clkc CLKID_I2C>;
231				#address-cells = <1>;
232				#size-cells = <0>;
233				status = "disabled";
234			};
235
236			i2c2: i2c@1d000 {
237				compatible = "amlogic,meson-axg-i2c";
238				reg = <0x0 0x1d000 0x0 0x20>;
239				interrupts = <GIC_SPI 215 IRQ_TYPE_EDGE_RISING>;
240				clocks = <&clkc CLKID_I2C>;
241				#address-cells = <1>;
242				#size-cells = <0>;
243				status = "disabled";
244			};
245
246			i2c3: i2c@1c000 {
247				compatible = "amlogic,meson-axg-i2c";
248				reg = <0x0 0x1c000 0x0 0x20>;
249				interrupts = <GIC_SPI 39 IRQ_TYPE_EDGE_RISING>;
250				clocks = <&clkc CLKID_I2C>;
251				#address-cells = <1>;
252				#size-cells = <0>;
253				status = "disabled";
254			};
255
256			uart_A: serial@24000 {
257				compatible = "amlogic,meson-gx-uart";
258				reg = <0x0 0x24000 0x0 0x18>;
259				interrupts = <GIC_SPI 26 IRQ_TYPE_EDGE_RISING>;
260				status = "disabled";
261				clocks = <&xtal>, <&clkc CLKID_UART0>, <&xtal>;
262				clock-names = "xtal", "pclk", "baud";
263			};
264
265			uart_B: serial@23000 {
266				compatible = "amlogic,meson-gx-uart";
267				reg = <0x0 0x23000 0x0 0x18>;
268				interrupts = <GIC_SPI 75 IRQ_TYPE_EDGE_RISING>;
269				status = "disabled";
270				clocks = <&xtal>, <&clkc CLKID_UART1>, <&xtal>;
271				clock-names = "xtal", "pclk", "baud";
272			};
273		};
274
275		ethmac: ethernet@ff3f0000 {
276			compatible = "amlogic,meson-gxbb-dwmac", "snps,dwmac";
277			reg = <0x0 0xff3f0000 0x0 0x10000
278				0x0 0xff634540 0x0 0x8>;
279			interrupts = <GIC_SPI 8 IRQ_TYPE_EDGE_RISING>;
280			interrupt-names = "macirq";
281			clocks = <&clkc CLKID_ETH>,
282				 <&clkc CLKID_FCLK_DIV2>,
283				 <&clkc CLKID_MPLL2>;
284			clock-names = "stmmaceth", "clkin0", "clkin1";
285			status = "disabled";
286		};
287
288		gic: interrupt-controller@ffc01000 {
289			compatible = "arm,gic-400";
290			reg = <0x0 0xffc01000 0 0x1000>,
291			      <0x0 0xffc02000 0 0x2000>,
292			      <0x0 0xffc04000 0 0x2000>,
293			      <0x0 0xffc06000 0 0x2000>;
294			interrupt-controller;
295			interrupts = <GIC_PPI 9
296				(GIC_CPU_MASK_SIMPLE(8) | IRQ_TYPE_LEVEL_HIGH)>;
297			#interrupt-cells = <3>;
298			#address-cells = <0>;
299		};
300
301		hiubus: bus@ff63c000 {
302			compatible = "simple-bus";
303			reg = <0x0 0xff63c000 0x0 0x1c00>;
304			#address-cells = <2>;
305			#size-cells = <2>;
306			ranges = <0x0 0x0 0x0 0xff63c000 0x0 0x1c00>;
307
308			sysctrl: system-controller@0 {
309				compatible = "amlogic,meson-axg-hhi-sysctrl", "syscon", "simple-mfd";
310				reg = <0 0 0 0x400>;
311
312				clkc: clock-controller {
313					compatible = "amlogic,axg-clkc";
314					#clock-cells = <1>;
315				};
316			};
317		};
318
319		mailbox: mailbox@ff63dc00 {
320			compatible = "amlogic,meson-gx-mhu", "amlogic,meson-gxbb-mhu";
321			reg = <0 0xff63dc00 0 0x400>;
322			interrupts = <GIC_SPI 208 IRQ_TYPE_EDGE_RISING>,
323				     <GIC_SPI 209 IRQ_TYPE_EDGE_RISING>,
324				     <GIC_SPI 210 IRQ_TYPE_EDGE_RISING>;
325			#mbox-cells = <1>;
326		};
327
328		periphs: periphs@ff634000 {
329			compatible = "simple-bus";
330			reg = <0x0 0xff634000 0x0 0x2000>;
331			#address-cells = <2>;
332			#size-cells = <2>;
333			ranges = <0x0 0x0 0x0 0xff634000 0x0 0x2000>;
334
335			hwrng: rng {
336				compatible = "amlogic,meson-rng";
337				reg = <0x0 0x18 0x0 0x4>;
338				clocks = <&clkc CLKID_RNG0>;
339				clock-names = "core";
340			};
341
342			pinctrl_periphs: pinctrl@480 {
343				compatible = "amlogic,meson-axg-periphs-pinctrl";
344				#address-cells = <2>;
345				#size-cells = <2>;
346				ranges;
347
348				gpio: bank@480 {
349					reg = <0x0 0x00480 0x0 0x40>,
350						<0x0 0x004e8 0x0 0x14>,
351						<0x0 0x00520 0x0 0x14>,
352						<0x0 0x00430 0x0 0x3c>;
353					reg-names = "mux", "pull", "pull-enable", "gpio";
354					gpio-controller;
355					#gpio-cells = <2>;
356					gpio-ranges = <&pinctrl_periphs 0 0 86>;
357				};
358
359				emmc_pins: emmc {
360					mux {
361						groups = "emmc_nand_d0",
362							"emmc_nand_d1",
363							"emmc_nand_d2",
364							"emmc_nand_d3",
365							"emmc_nand_d4",
366							"emmc_nand_d5",
367							"emmc_nand_d6",
368							"emmc_nand_d7",
369							"emmc_clk",
370							"emmc_cmd",
371							"emmc_ds";
372						function = "emmc";
373					};
374				};
375
376				emmc_clk_gate_pins: emmc_clk_gate {
377					mux {
378						groups = "BOOT_8";
379						function = "gpio_periphs";
380					};
381					cfg-pull-down {
382						pins = "BOOT_8";
383						bias-pull-down;
384					};
385				};
386
387				sdio_pins: sdio {
388					mux {
389						groups = "sdio_d0",
390							"sdio_d1",
391							"sdio_d2",
392							"sdio_d3",
393							"sdio_cmd",
394							"sdio_clk";
395						function = "sdio";
396					};
397				};
398
399				sdio_clk_gate_pins: sdio_clk_gate {
400					mux {
401						groups = "GPIOX_4";
402						function = "gpio_periphs";
403					};
404					cfg-pull-down {
405						pins = "GPIOX_4";
406						bias-pull-down;
407					};
408				};
409
410				eth_rmii_x_pins: eth-x-rmii {
411					mux {
412						groups = "eth_mdio_x",
413						       "eth_mdc_x",
414						       "eth_rgmii_rx_clk_x",
415						       "eth_rx_dv_x",
416						       "eth_rxd0_x",
417						       "eth_rxd1_x",
418						       "eth_txen_x",
419						       "eth_txd0_x",
420						       "eth_txd1_x";
421						function = "eth";
422					};
423				};
424
425				eth_rmii_y_pins: eth-y-rmii {
426					mux {
427						groups = "eth_mdio_y",
428						       "eth_mdc_y",
429						       "eth_rgmii_rx_clk_y",
430						       "eth_rx_dv_y",
431						       "eth_rxd0_y",
432						       "eth_rxd1_y",
433						       "eth_txen_y",
434						       "eth_txd0_y",
435						       "eth_txd1_y";
436						function = "eth";
437					};
438				};
439
440				eth_rgmii_x_pins: eth-x-rgmii {
441					mux {
442						groups = "eth_mdio_x",
443						       "eth_mdc_x",
444						       "eth_rgmii_rx_clk_x",
445						       "eth_rx_dv_x",
446						       "eth_rxd0_x",
447						       "eth_rxd1_x",
448						       "eth_rxd2_rgmii",
449						       "eth_rxd3_rgmii",
450						       "eth_rgmii_tx_clk",
451						       "eth_txen_x",
452						       "eth_txd0_x",
453						       "eth_txd1_x",
454						       "eth_txd2_rgmii",
455						       "eth_txd3_rgmii";
456						function = "eth";
457					};
458				};
459
460				eth_rgmii_y_pins: eth-y-rgmii {
461					mux {
462						groups = "eth_mdio_y",
463						       "eth_mdc_y",
464						       "eth_rgmii_rx_clk_y",
465						       "eth_rx_dv_y",
466						       "eth_rxd0_y",
467						       "eth_rxd1_y",
468						       "eth_rxd2_rgmii",
469						       "eth_rxd3_rgmii",
470						       "eth_rgmii_tx_clk",
471						       "eth_txen_y",
472						       "eth_txd0_y",
473						       "eth_txd1_y",
474						       "eth_txd2_rgmii",
475						       "eth_txd3_rgmii";
476						function = "eth";
477					};
478				};
479
480				pwm_a_a_pins: pwm_a_a {
481					mux {
482						groups = "pwm_a_a";
483						function = "pwm_a";
484					};
485				};
486
487				pwm_a_x18_pins: pwm_a_x18 {
488					mux {
489						groups = "pwm_a_x18";
490						function = "pwm_a";
491					};
492				};
493
494				pwm_a_x20_pins: pwm_a_x20 {
495					mux {
496						groups = "pwm_a_x20";
497						function = "pwm_a";
498					};
499				};
500
501				pwm_a_z_pins: pwm_a_z {
502					mux {
503						groups = "pwm_a_z";
504						function = "pwm_a";
505					};
506				};
507
508				pwm_b_a_pins: pwm_b_a {
509					mux {
510						groups = "pwm_b_a";
511						function = "pwm_b";
512					};
513				};
514
515				pwm_b_x_pins: pwm_b_x {
516					mux {
517						groups = "pwm_b_x";
518						function = "pwm_b";
519					};
520				};
521
522				pwm_b_z_pins: pwm_b_z {
523					mux {
524						groups = "pwm_b_z";
525						function = "pwm_b";
526					};
527				};
528
529				pwm_c_a_pins: pwm_c_a {
530					mux {
531						groups = "pwm_c_a";
532						function = "pwm_c";
533					};
534				};
535
536				pwm_c_x10_pins: pwm_c_x10 {
537					mux {
538						groups = "pwm_c_x10";
539						function = "pwm_c";
540					};
541				};
542
543				pwm_c_x17_pins: pwm_c_x17 {
544					mux {
545						groups = "pwm_c_x17";
546						function = "pwm_c";
547					};
548				};
549
550				pwm_d_x11_pins: pwm_d_x11 {
551					mux {
552						groups = "pwm_d_x11";
553						function = "pwm_d";
554					};
555				};
556
557				pwm_d_x16_pins: pwm_d_x16 {
558					mux {
559						groups = "pwm_d_x16";
560						function = "pwm_d";
561					};
562				};
563
564				spdif_out_z_pins: spdif_out_z {
565					mux {
566						groups = "spdif_out_z";
567						function = "spdif_out";
568					};
569				};
570
571				spdif_out_a1_pins: spdif_out_a1 {
572					mux {
573						groups = "spdif_out_a1";
574						function = "spdif_out";
575					};
576				};
577
578				spdif_out_a11_pins: spdif_out_a11 {
579					mux {
580						groups = "spdif_out_a11";
581						function = "spdif_out";
582					};
583				};
584
585				spdif_out_a19_pins: spdif_out_a19 {
586					mux {
587						groups = "spdif_out_a19";
588						function = "spdif_out";
589					};
590				};
591
592				spdif_out_a20_pins: spdif_out_a20 {
593					mux {
594						groups = "spdif_out_a20";
595						function = "spdif_out";
596					};
597				};
598
599				spi0_pins: spi0 {
600					mux {
601						groups = "spi0_miso",
602							"spi0_mosi",
603							"spi0_clk";
604						function = "spi0";
605					};
606				};
607
608				spi0_ss0_pins: spi0_ss0 {
609					mux {
610						groups = "spi0_ss0";
611						function = "spi0";
612					};
613				};
614
615				spi0_ss1_pins: spi0_ss1 {
616					mux {
617						groups = "spi0_ss1";
618						function = "spi0";
619					};
620				};
621
622				spi0_ss2_pins: spi0_ss2 {
623					mux {
624						groups = "spi0_ss2";
625						function = "spi0";
626					};
627				};
628
629
630				spi1_a_pins: spi1_a {
631					mux {
632						groups = "spi1_miso_a",
633							"spi1_mosi_a",
634							"spi1_clk_a";
635						function = "spi1";
636					};
637				};
638
639				spi1_ss0_a_pins: spi1_ss0_a {
640					mux {
641						groups = "spi1_ss0_a";
642						function = "spi1";
643					};
644				};
645
646				spi1_ss1_pins: spi1_ss1 {
647					mux {
648						groups = "spi1_ss1";
649						function = "spi1";
650					};
651				};
652
653				spi1_x_pins: spi1_x {
654					mux {
655						groups = "spi1_miso_x",
656							"spi1_mosi_x",
657							"spi1_clk_x";
658						function = "spi1";
659					};
660				};
661
662				spi1_ss0_x_pins: spi1_ss0_x {
663					mux {
664						groups = "spi1_ss0_x";
665						function = "spi1";
666					};
667				};
668
669				i2c0_pins: i2c0 {
670					mux {
671						groups = "i2c0_sck",
672							"i2c0_sda";
673						function = "i2c0";
674					};
675				};
676
677				i2c1_z_pins: i2c1_z {
678					mux {
679						groups = "i2c1_sck_z",
680							"i2c1_sda_z";
681						function = "i2c1";
682					};
683				};
684
685				i2c1_x_pins: i2c1_x {
686					mux {
687						groups = "i2c1_sck_x",
688							"i2c1_sda_x";
689						function = "i2c1";
690					};
691				};
692
693				i2c2_x_pins: i2c2_x {
694					mux {
695						groups = "i2c2_sck_x",
696							"i2c2_sda_x";
697						function = "i2c2";
698					};
699				};
700
701				i2c2_a_pins: i2c2_a {
702					mux {
703						groups = "i2c2_sck_a",
704							"i2c2_sda_a";
705						function = "i2c2";
706					};
707				};
708
709				i2c3_a6_pins: i2c3_a6 {
710					mux {
711						groups = "i2c3_sda_a6",
712							"i2c3_sck_a7";
713						function = "i2c3";
714					};
715				};
716
717				i2c3_a12_pins: i2c3_a12 {
718					mux {
719						groups = "i2c3_sda_a12",
720							"i2c3_sck_a13";
721						function = "i2c3";
722					};
723				};
724
725				i2c3_a19_pins: i2c3_a19 {
726					mux {
727						groups = "i2c3_sda_a19",
728							"i2c3_sck_a20";
729						function = "i2c3";
730					};
731				};
732
733				uart_a_pins: uart_a {
734					mux {
735						groups = "uart_tx_a",
736							"uart_rx_a";
737						function = "uart_a";
738					};
739				};
740
741				uart_a_cts_rts_pins: uart_a_cts_rts {
742					mux {
743						groups = "uart_cts_a",
744							"uart_rts_a";
745						function = "uart_a";
746					};
747				};
748
749				uart_b_x_pins: uart_b_x {
750					mux {
751						groups = "uart_tx_b_x",
752							"uart_rx_b_x";
753						function = "uart_b";
754					};
755				};
756
757				uart_b_x_cts_rts_pins: uart_b_x_cts_rts {
758					mux {
759						groups = "uart_cts_b_x",
760							"uart_rts_b_x";
761						function = "uart_b";
762					};
763				};
764
765				uart_b_z_pins: uart_b_z {
766					mux {
767						groups = "uart_tx_b_z",
768							"uart_rx_b_z";
769						function = "uart_b";
770					};
771				};
772
773				uart_b_z_cts_rts_pins: uart_b_z_cts_rts {
774					mux {
775						groups = "uart_cts_b_z",
776							"uart_rts_b_z";
777						function = "uart_b";
778					};
779				};
780
781				uart_ao_b_z_pins: uart_ao_b_z {
782					mux {
783						groups = "uart_ao_tx_b_z",
784							"uart_ao_rx_b_z";
785						function = "uart_ao_b_z";
786					};
787				};
788
789				uart_ao_b_z_cts_rts_pins: uart_ao_b_z_cts_rts {
790					mux {
791						groups = "uart_ao_cts_b_z",
792							"uart_ao_rts_b_z";
793						function = "uart_ao_b_z";
794					};
795				};
796
797				mclk_b_pins: mclk_b {
798					mux {
799						groups = "mclk_b";
800						function = "mclk_b";
801					};
802				};
803
804				mclk_c_pins: mclk_c {
805					mux {
806						groups = "mclk_c";
807						function = "mclk_c";
808					};
809				};
810
811				tdma_sclk_pins: tdma_sclk {
812					mux {
813						groups = "tdma_sclk";
814						function = "tdma";
815					};
816				};
817
818				tdma_sclk_slv_pins: tdma_sclk_slv {
819					mux {
820						groups = "tdma_sclk_slv";
821						function = "tdma";
822					};
823				};
824
825				tdma_fs_pins: tdma_fs {
826					mux {
827						groups = "tdma_fs";
828						function = "tdma";
829					};
830				};
831
832				tdma_fs_slv_pins: tdma_fs_slv {
833					mux {
834						groups = "tdma_fs_slv";
835						function = "tdma";
836					};
837				};
838
839				tdma_din0_pins: tdma_din0 {
840					mux {
841						groups = "tdma_din0";
842						function = "tdma";
843					};
844				};
845
846				tdma_dout0_x14_pins: tdma_dout0_x14 {
847					mux {
848						groups = "tdma_dout0_x14";
849						function = "tdma";
850					};
851				};
852
853				tdma_dout0_x15_pins: tdma_dout0_x15 {
854					mux {
855						groups = "tdma_dout0_x15";
856						function = "tdma";
857					};
858				};
859
860				tdma_dout1_pins: tdma_dout1 {
861					mux {
862						groups = "tdma_dout1";
863						function = "tdma";
864					};
865				};
866
867				tdma_din1_pins: tdma_din1 {
868					mux {
869						groups = "tdma_din1";
870						function = "tdma";
871					};
872				};
873
874				tdmb_sclk_pins: tdmb_sclk {
875					mux {
876						groups = "tdmb_sclk";
877						function = "tdmb";
878					};
879				};
880
881				tdmb_sclk_slv_pins: tdmb_sclk_slv {
882					mux {
883						groups = "tdmb_sclk_slv";
884						function = "tdmb";
885					};
886				};
887
888				tdmb_fs_pins: tdmb_fs {
889					mux {
890						groups = "tdmb_fs";
891						function = "tdmb";
892					};
893				};
894
895				tdmb_fs_slv_pins: tdmb_fs_slv {
896					mux {
897						groups = "tdmb_fs_slv";
898						function = "tdmb";
899					};
900				};
901
902				tdmb_din0_pins: tdmb_din0 {
903					mux {
904						groups = "tdmb_din0";
905						function = "tdmb";
906					};
907				};
908
909				tdmb_dout0_pins: tdmb_dout0 {
910					mux {
911						groups = "tdmb_dout0";
912						function = "tdmb";
913					};
914				};
915
916				tdmb_din1_pins: tdmb_din1 {
917					mux {
918						groups = "tdmb_din1";
919						function = "tdmb";
920					};
921				};
922
923				tdmb_dout1_pins: tdmb_dout1 {
924					mux {
925						groups = "tdmb_dout1";
926						function = "tdmb";
927					};
928				};
929
930				tdmb_din2_pins: tdmb_din2 {
931					mux {
932						groups = "tdmb_din2";
933						function = "tdmb";
934					};
935				};
936
937				tdmb_dout2_pins: tdmb_dout2 {
938					mux {
939						groups = "tdmb_dout2";
940						function = "tdmb";
941					};
942				};
943
944				tdmb_din3_pins: tdmb_din3 {
945					mux {
946						groups = "tdmb_din3";
947						function = "tdmb";
948					};
949				};
950
951				tdmb_dout3_pins: tdmb_dout3 {
952					mux {
953						groups = "tdmb_dout3";
954						function = "tdmb";
955					};
956				};
957
958				tdmc_sclk_pins: tdmc_sclk {
959					mux {
960						groups = "tdmc_sclk";
961						function = "tdmc";
962					};
963				};
964
965				tdmc_sclk_slv_pins: tdmc_sclk_slv {
966					mux {
967						groups = "tdmc_sclk_slv";
968						function = "tdmc";
969					};
970				};
971
972				tdmc_fs_pins: tdmc_fs {
973					mux {
974						groups = "tdmc_fs";
975						function = "tdmc";
976					};
977				};
978
979				tdmc_fs_slv_pins: tdmc_fs_slv {
980					mux {
981						groups = "tdmc_fs_slv";
982						function = "tdmc";
983					};
984				};
985
986				tdmc_din0_pins: tdmc_din0 {
987					mux {
988						groups = "tdmc_din0";
989						function = "tdmc";
990					};
991				};
992
993				tdmc_dout0_pins: tdmc_dout0 {
994					mux {
995						groups = "tdmc_dout0";
996						function = "tdmc";
997					};
998				};
999
1000				tdmc_din1_pins: tdmc_din1 {
1001					mux {
1002						groups = "tdmc_din1";
1003						function = "tdmc";
1004					};
1005				};
1006
1007				tdmc_dout1_pins: tdmc_dout1 {
1008					mux {
1009						groups = "tdmc_dout1";
1010						function = "tdmc";
1011					};
1012				};
1013
1014				tdmc_din2_pins: tdmc_din2 {
1015					mux {
1016						groups = "tdmc_din2";
1017						function = "tdmc";
1018					};
1019				};
1020
1021				tdmc_dout2_pins: tdmc_dout2 {
1022					mux {
1023						groups = "tdmc_dout2";
1024						function = "tdmc";
1025					};
1026				};
1027
1028				tdmc_din3_pins: tdmc_din3 {
1029					mux {
1030						groups = "tdmc_din3";
1031						function = "tdmc";
1032					};
1033				};
1034
1035				tdmc_dout3_pins: tdmc_dout3 {
1036					mux {
1037						groups = "tdmc_dout3";
1038						function = "tdmc";
1039					};
1040				};
1041			};
1042		};
1043
1044		sram: sram@fffc0000 {
1045			compatible = "amlogic,meson-axg-sram", "mmio-sram";
1046			reg = <0x0 0xfffc0000 0x0 0x20000>;
1047			#address-cells = <1>;
1048			#size-cells = <1>;
1049			ranges = <0 0x0 0xfffc0000 0x20000>;
1050
1051			cpu_scp_lpri: scp-shmem@0 {
1052				compatible = "amlogic,meson-axg-scp-shmem";
1053				reg = <0x13000 0x400>;
1054			};
1055
1056			cpu_scp_hpri: scp-shmem@200 {
1057				compatible = "amlogic,meson-axg-scp-shmem";
1058				reg = <0x13400 0x400>;
1059			};
1060		};
1061
1062		aobus: bus@ff800000 {
1063			compatible = "simple-bus";
1064			reg = <0x0 0xff800000 0x0 0x100000>;
1065			#address-cells = <2>;
1066			#size-cells = <2>;
1067			ranges = <0x0 0x0 0x0 0xff800000 0x0 0x100000>;
1068
1069			sysctrl_AO: sys-ctrl@0 {
1070				compatible = "amlogic,meson-axg-ao-sysctrl", "syscon", "simple-mfd";
1071				reg =  <0x0 0x0 0x0 0x100>;
1072
1073				clkc_AO: clock-controller {
1074					compatible = "amlogic,meson-axg-aoclkc";
1075					#clock-cells = <1>;
1076					#reset-cells = <1>;
1077				};
1078			};
1079
1080			pinctrl_aobus: pinctrl@14 {
1081				compatible = "amlogic,meson-axg-aobus-pinctrl";
1082				#address-cells = <2>;
1083				#size-cells = <2>;
1084				ranges;
1085
1086				gpio_ao: bank@14 {
1087					reg = <0x0 0x00014 0x0 0x8>,
1088						<0x0 0x0002c 0x0 0x4>,
1089						<0x0 0x00024 0x0 0x8>;
1090					reg-names = "mux", "pull", "gpio";
1091					gpio-controller;
1092					#gpio-cells = <2>;
1093					gpio-ranges = <&pinctrl_aobus 0 0 15>;
1094				};
1095
1096				i2c_ao_sck_4_pins: i2c_ao_sck_4 {
1097					mux {
1098						groups = "i2c_ao_sck_4";
1099						function = "i2c_ao";
1100					};
1101				};
1102
1103				i2c_ao_sck_8_pins: i2c_ao_sck_8 {
1104					mux {
1105						groups = "i2c_ao_sck_8";
1106						function = "i2c_ao";
1107					};
1108				};
1109
1110				i2c_ao_sck_10_pins: i2c_ao_sck_10 {
1111					mux {
1112						groups = "i2c_ao_sck_10";
1113						function = "i2c_ao";
1114					};
1115				};
1116
1117				i2c_ao_sda_5_pins: i2c_ao_sda_5 {
1118					mux {
1119						groups = "i2c_ao_sda_5";
1120						function = "i2c_ao";
1121					};
1122				};
1123
1124				i2c_ao_sda_9_pins: i2c_ao_sda_9 {
1125					mux {
1126						groups = "i2c_ao_sda_9";
1127						function = "i2c_ao";
1128					};
1129				};
1130
1131				i2c_ao_sda_11_pins: i2c_ao_sda_11 {
1132					mux {
1133						groups = "i2c_ao_sda_11";
1134						function = "i2c_ao";
1135					};
1136				};
1137
1138				remote_input_ao_pins: remote_input_ao {
1139					mux {
1140						groups = "remote_input_ao";
1141						function = "remote_input_ao";
1142					};
1143				};
1144
1145				uart_ao_a_pins: uart_ao_a {
1146					mux {
1147						groups = "uart_ao_tx_a",
1148							"uart_ao_rx_a";
1149						function = "uart_ao_a";
1150					};
1151				};
1152
1153				uart_ao_a_cts_rts_pins: uart_ao_a_cts_rts {
1154					mux {
1155						groups = "uart_ao_cts_a",
1156							"uart_ao_rts_a";
1157						function = "uart_ao_a";
1158					};
1159				};
1160
1161				uart_ao_b_pins: uart_ao_b {
1162					mux {
1163						groups = "uart_ao_tx_b",
1164							"uart_ao_rx_b";
1165						function = "uart_ao_b";
1166					};
1167				};
1168
1169				uart_ao_b_cts_rts_pins: uart_ao_b_cts_rts {
1170					mux {
1171						groups = "uart_ao_cts_b",
1172							"uart_ao_rts_b";
1173						function = "uart_ao_b";
1174					};
1175				};
1176			};
1177
1178			sec_AO: ao-secure@140 {
1179				compatible = "amlogic,meson-gx-ao-secure", "syscon";
1180				reg = <0x0 0x140 0x0 0x140>;
1181				amlogic,has-chip-id;
1182			};
1183
1184			pwm_AO_ab: pwm@7000 {
1185				compatible = "amlogic,meson-axg-ao-pwm";
1186				reg = <0x0 0x07000 0x0 0x20>;
1187				#pwm-cells = <3>;
1188				status = "disabled";
1189			};
1190
1191			pwm_AO_cd: pwm@2000 {
1192				compatible = "amlogic,meson-axg-ao-pwm";
1193				reg = <0x0 0x02000  0x0 0x20>;
1194				#pwm-cells = <3>;
1195				status = "disabled";
1196			};
1197
1198			i2c_AO: i2c@5000 {
1199				compatible = "amlogic,meson-axg-i2c";
1200				reg = <0x0 0x05000 0x0 0x20>;
1201				interrupts = <GIC_SPI 195 IRQ_TYPE_EDGE_RISING>;
1202				clocks = <&clkc CLKID_AO_I2C>;
1203				#address-cells = <1>;
1204				#size-cells = <0>;
1205				status = "disabled";
1206			};
1207
1208			uart_AO: serial@3000 {
1209				compatible = "amlogic,meson-gx-uart", "amlogic,meson-ao-uart";
1210				reg = <0x0 0x3000 0x0 0x18>;
1211				interrupts = <GIC_SPI 193 IRQ_TYPE_EDGE_RISING>;
1212				clocks = <&xtal>, <&clkc_AO CLKID_AO_UART1>, <&xtal>;
1213				clock-names = "xtal", "pclk", "baud";
1214				status = "disabled";
1215			};
1216
1217			uart_AO_B: serial@4000 {
1218				compatible = "amlogic,meson-gx-uart", "amlogic,meson-ao-uart";
1219				reg = <0x0 0x4000 0x0 0x18>;
1220				interrupts = <GIC_SPI 197 IRQ_TYPE_EDGE_RISING>;
1221				clocks = <&xtal>, <&clkc_AO CLKID_AO_UART2>, <&xtal>;
1222				clock-names = "xtal", "pclk", "baud";
1223				status = "disabled";
1224			};
1225
1226			ir: ir@8000 {
1227				compatible = "amlogic,meson-gxbb-ir";
1228				reg = <0x0 0x8000 0x0 0x20>;
1229				interrupts = <GIC_SPI 196 IRQ_TYPE_EDGE_RISING>;
1230				status = "disabled";
1231			};
1232
1233			saradc: adc@9000 {
1234				compatible = "amlogic,meson-axg-saradc",
1235					"amlogic,meson-saradc";
1236				reg = <0x0 0x9000 0x0 0x38>;
1237				#io-channel-cells = <1>;
1238				interrupts = <GIC_SPI 73 IRQ_TYPE_EDGE_RISING>;
1239				clocks = <&xtal>,
1240					<&clkc_AO CLKID_AO_SAR_ADC>,
1241					<&clkc_AO CLKID_AO_SAR_ADC_CLK>,
1242					<&clkc_AO CLKID_AO_SAR_ADC_SEL>;
1243				clock-names = "clkin", "core", "adc_clk", "adc_sel";
1244				status = "disabled";
1245			};
1246		};
1247	};
1248};
1249