2 * Copyright (C) 2016 Icenowy Zheng <icenowy@aosc.xyz>
4 * This file is dual-licensed: you can use it either under the terms
5 * of the GPL or the X11 license, at your option. Note that this dual
6 * licensing only applies to this file, and not this project as a
9 * a) This file is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License as
11 * published by the Free Software Foundation; either version 2 of the
12 * License, or (at your option) any later version.
14 * This file is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
21 * b) Permission is hereby granted, free of charge, to any person
22 * obtaining a copy of this software and associated documentation
23 * files (the "Software"), to deal in the Software without
24 * restriction, including without limitation the rights to use,
25 * copy, modify, merge, publish, distribute, sublicense, and/or
26 * sell copies of the Software, and to permit persons to whom the
27 * Software is furnished to do so, subject to the following
30 * The above copyright notice and this permission notice shall be
31 * included in all copies or substantial portions of the Software.
33 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
34 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
35 * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
36 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
37 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
38 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
39 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
40 * OTHER DEALINGS IN THE SOFTWARE.
43 #include <dt-bindings/interrupt-controller/arm-gic.h>
44 #include <dt-bindings/clock/sun8i-v3s-ccu.h>
45 #include <dt-bindings/reset/sun8i-v3s-ccu.h>
50 interrupt-parent = <&gic>;
57 compatible = "arm,cortex-a7";
60 clocks = <&ccu CLK_CPU>;
65 compatible = "allwinner,sun8i-v3s-display-engine";
66 allwinner,pipelines = <&mixer0>;
71 compatible = "arm,armv7-timer";
72 interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
73 <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
74 <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
75 <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
85 compatible = "fixed-clock";
86 clock-frequency = <24000000>;
87 clock-accuracy = <50000>;
88 clock-output-names = "osc24M";
93 compatible = "fixed-clock";
94 clock-frequency = <32768>;
95 clock-accuracy = <50000>;
96 clock-output-names = "ext-osc32k";
101 compatible = "simple-bus";
102 #address-cells = <1>;
106 display_clocks: clock@1000000 {
107 compatible = "allwinner,sun8i-v3s-de2-clk";
108 reg = <0x01000000 0x100000>;
109 clocks = <&ccu CLK_BUS_DE>,
113 resets = <&ccu RST_BUS_DE>;
118 mixer0: mixer@1100000 {
119 compatible = "allwinner,sun8i-v3s-de2-mixer";
120 reg = <0x01100000 0x100000>;
121 clocks = <&display_clocks 0>,
125 resets = <&display_clocks 0>;
126 assigned-clocks = <&display_clocks 6>;
127 assigned-clock-rates = <150000000>;
130 #address-cells = <1>;
136 mixer0_out_tcon0: endpoint {
137 remote-endpoint = <&tcon0_in_mixer0>;
143 tcon0: lcd-controller@1c0c000 {
144 compatible = "allwinner,sun8i-v3s-tcon";
145 reg = <0x01c0c000 0x1000>;
146 interrupts = <GIC_SPI 86 IRQ_TYPE_LEVEL_HIGH>;
147 clocks = <&ccu CLK_BUS_TCON0>,
151 clock-output-names = "tcon-pixel-clock";
153 resets = <&ccu RST_BUS_TCON0>;
158 #address-cells = <1>;
164 tcon0_in_mixer0: endpoint {
165 remote-endpoint = <&mixer0_out_tcon0>;
170 #address-cells = <1>;
179 compatible = "allwinner,sun7i-a20-mmc";
180 reg = <0x01c0f000 0x1000>;
181 clocks = <&ccu CLK_BUS_MMC0>,
183 <&ccu CLK_MMC0_OUTPUT>,
184 <&ccu CLK_MMC0_SAMPLE>;
189 resets = <&ccu RST_BUS_MMC0>;
191 interrupts = <GIC_SPI 60 IRQ_TYPE_LEVEL_HIGH>;
192 pinctrl-names = "default";
193 pinctrl-0 = <&mmc0_pins>;
195 #address-cells = <1>;
200 compatible = "allwinner,sun7i-a20-mmc";
201 reg = <0x01c10000 0x1000>;
202 clocks = <&ccu CLK_BUS_MMC1>,
204 <&ccu CLK_MMC1_OUTPUT>,
205 <&ccu CLK_MMC1_SAMPLE>;
210 resets = <&ccu RST_BUS_MMC1>;
212 interrupts = <GIC_SPI 61 IRQ_TYPE_LEVEL_HIGH>;
213 pinctrl-names = "default";
214 pinctrl-0 = <&mmc1_pins>;
216 #address-cells = <1>;
221 compatible = "allwinner,sun7i-a20-mmc";
222 reg = <0x01c11000 0x1000>;
223 clocks = <&ccu CLK_BUS_MMC2>,
225 <&ccu CLK_MMC2_OUTPUT>,
226 <&ccu CLK_MMC2_SAMPLE>;
231 resets = <&ccu RST_BUS_MMC2>;
233 interrupts = <GIC_SPI 62 IRQ_TYPE_LEVEL_HIGH>;
235 #address-cells = <1>;
239 usb_otg: usb@1c19000 {
240 compatible = "allwinner,sun8i-h3-musb";
241 reg = <0x01c19000 0x0400>;
242 clocks = <&ccu CLK_BUS_OTG>;
243 resets = <&ccu RST_BUS_OTG>;
244 interrupts = <GIC_SPI 71 IRQ_TYPE_LEVEL_HIGH>;
245 interrupt-names = "mc";
248 extcon = <&usbphy 0>;
252 usbphy: phy@1c19400 {
253 compatible = "allwinner,sun8i-v3s-usb-phy";
254 reg = <0x01c19400 0x2c>,
256 reg-names = "phy_ctrl",
258 clocks = <&ccu CLK_USB_PHY0>;
259 clock-names = "usb0_phy";
260 resets = <&ccu RST_USB_PHY0>;
261 reset-names = "usb0_reset";
267 compatible = "allwinner,sun8i-v3s-ccu";
268 reg = <0x01c20000 0x400>;
269 clocks = <&osc24M>, <&rtc 0>;
270 clock-names = "hosc", "losc";
277 compatible = "allwinner,sun8i-v3-rtc";
278 reg = <0x01c20400 0x54>;
279 interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>,
280 <GIC_SPI 41 IRQ_TYPE_LEVEL_HIGH>;
282 clock-output-names = "osc32k", "osc32k-out";
285 pio: pinctrl@1c20800 {
286 compatible = "allwinner,sun8i-v3s-pinctrl";
287 reg = <0x01c20800 0x400>;
288 interrupts = <GIC_SPI 15 IRQ_TYPE_LEVEL_HIGH>,
289 <GIC_SPI 17 IRQ_TYPE_LEVEL_HIGH>;
290 clocks = <&ccu CLK_BUS_PIO>, <&osc24M>, <&rtc 0>;
291 clock-names = "apb", "hosc", "losc";
294 interrupt-controller;
295 #interrupt-cells = <3>;
297 i2c0_pins: i2c0-pins {
302 uart0_pb_pins: uart0-pb-pins {
307 mmc0_pins: mmc0-pins {
308 pins = "PF0", "PF1", "PF2", "PF3",
311 drive-strength = <30>;
315 mmc1_pins: mmc1-pins {
316 pins = "PG0", "PG1", "PG2", "PG3",
319 drive-strength = <30>;
323 spi0_pins: spi0-pins {
324 pins = "PC0", "PC1", "PC2", "PC3";
330 compatible = "allwinner,sun8i-v3s-timer";
331 reg = <0x01c20c00 0xa0>;
332 interrupts = <GIC_SPI 18 IRQ_TYPE_LEVEL_HIGH>,
333 <GIC_SPI 19 IRQ_TYPE_LEVEL_HIGH>,
334 <GIC_SPI 20 IRQ_TYPE_LEVEL_HIGH>;
338 wdt0: watchdog@1c20ca0 {
339 compatible = "allwinner,sun6i-a31-wdt";
340 reg = <0x01c20ca0 0x20>;
341 interrupts = <GIC_SPI 25 IRQ_TYPE_LEVEL_HIGH>;
345 lradc: lradc@1c22800 {
346 compatible = "allwinner,sun4i-a10-lradc-keys";
347 reg = <0x01c22800 0x400>;
348 interrupts = <GIC_SPI 30 IRQ_TYPE_LEVEL_HIGH>;
352 uart0: serial@1c28000 {
353 compatible = "snps,dw-apb-uart";
354 reg = <0x01c28000 0x400>;
355 interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
358 clocks = <&ccu CLK_BUS_UART0>;
359 resets = <&ccu RST_BUS_UART0>;
363 uart1: serial@1c28400 {
364 compatible = "snps,dw-apb-uart";
365 reg = <0x01c28400 0x400>;
366 interrupts = <GIC_SPI 1 IRQ_TYPE_LEVEL_HIGH>;
369 clocks = <&ccu CLK_BUS_UART1>;
370 resets = <&ccu RST_BUS_UART1>;
374 uart2: serial@1c28800 {
375 compatible = "snps,dw-apb-uart";
376 reg = <0x01c28800 0x400>;
377 interrupts = <GIC_SPI 2 IRQ_TYPE_LEVEL_HIGH>;
380 clocks = <&ccu CLK_BUS_UART2>;
381 resets = <&ccu RST_BUS_UART2>;
386 compatible = "allwinner,sun6i-a31-i2c";
387 reg = <0x01c2ac00 0x400>;
388 interrupts = <GIC_SPI 6 IRQ_TYPE_LEVEL_HIGH>;
389 clocks = <&ccu CLK_BUS_I2C0>;
390 resets = <&ccu RST_BUS_I2C0>;
391 pinctrl-names = "default";
392 pinctrl-0 = <&i2c0_pins>;
394 #address-cells = <1>;
399 compatible = "allwinner,sun6i-a31-i2c";
400 reg = <0x01c2b000 0x400>;
401 interrupts = <GIC_SPI 7 IRQ_TYPE_LEVEL_HIGH>;
402 clocks = <&ccu CLK_BUS_I2C1>;
403 resets = <&ccu RST_BUS_I2C1>;
405 #address-cells = <1>;
410 compatible = "allwinner,sun8i-h3-spi";
411 reg = <0x01c68000 0x1000>;
412 interrupts = <GIC_SPI 65 IRQ_TYPE_LEVEL_HIGH>;
413 clocks = <&ccu CLK_BUS_SPI0>, <&ccu CLK_SPI0>;
414 clock-names = "ahb", "mod";
415 pinctrl-names = "default";
416 pinctrl-0 = <&spi0_pins>;
417 resets = <&ccu RST_BUS_SPI0>;
419 #address-cells = <1>;
423 gic: interrupt-controller@1c81000 {
424 compatible = "arm,gic-400";
425 reg = <0x01c81000 0x1000>,
429 interrupt-controller;
430 #interrupt-cells = <3>;
431 interrupts = <GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;