199767f8919635c4928607450d9e0abb932109ceToomas Soome/*-
199767f8919635c4928607450d9e0abb932109ceToomas Soome * Copyright (c) 2014 Ganbold Tsagaankhuu <ganbold@freebsd.org>
199767f8919635c4928607450d9e0abb932109ceToomas Soome * All rights reserved.
199767f8919635c4928607450d9e0abb932109ceToomas Soome *
199767f8919635c4928607450d9e0abb932109ceToomas Soome * Redistribution and use in source and binary forms, with or without
199767f8919635c4928607450d9e0abb932109ceToomas Soome * modification, are permitted provided that the following conditions
199767f8919635c4928607450d9e0abb932109ceToomas Soome * are met:
199767f8919635c4928607450d9e0abb932109ceToomas Soome * 1. Redistributions of source code must retain the above copyright
199767f8919635c4928607450d9e0abb932109ceToomas Soome * notice, this list of conditions and the following disclaimer.
199767f8919635c4928607450d9e0abb932109ceToomas Soome * 2. Redistributions in binary form must reproduce the above copyright
199767f8919635c4928607450d9e0abb932109ceToomas Soome * notice, this list of conditions and the following disclaimer in the
199767f8919635c4928607450d9e0abb932109ceToomas Soome * documentation and/or other materials provided with the distribution.
199767f8919635c4928607450d9e0abb932109ceToomas Soome *
199767f8919635c4928607450d9e0abb932109ceToomas Soome * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
199767f8919635c4928607450d9e0abb932109ceToomas Soome * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
199767f8919635c4928607450d9e0abb932109ceToomas Soome * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
199767f8919635c4928607450d9e0abb932109ceToomas Soome * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
199767f8919635c4928607450d9e0abb932109ceToomas Soome * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
199767f8919635c4928607450d9e0abb932109ceToomas Soome * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
199767f8919635c4928607450d9e0abb932109ceToomas Soome * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
199767f8919635c4928607450d9e0abb932109ceToomas Soome * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
199767f8919635c4928607450d9e0abb932109ceToomas Soome * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
199767f8919635c4928607450d9e0abb932109ceToomas Soome * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
199767f8919635c4928607450d9e0abb932109ceToomas Soome * SUCH DAMAGE.
199767f8919635c4928607450d9e0abb932109ceToomas Soome *
199767f8919635c4928607450d9e0abb932109ceToomas Soome * $FreeBSD$
199767f8919635c4928607450d9e0abb932109ceToomas Soome */
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome#include <dt-bindings/interrupt-controller/arm-gic.h>
199767f8919635c4928607450d9e0abb932109ceToomas Soome#include <dt-bindings/pinctrl/sun4i-a10.h>
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome/ {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun7i-a20";
199767f8919635c4928607450d9e0abb932109ceToomas Soome #address-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome #size-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome aliases {
199767f8919635c4928607450d9e0abb932109ceToomas Soome soc = &SOC;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome timer {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "arm,armv7-timer";
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_PPI 13 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <GIC_PPI 14 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <GIC_PPI 11 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <GIC_PPI 10 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_LOW)>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome SOC: a20 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome #address-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome #size-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "simple-bus";
199767f8919635c4928607450d9e0abb932109ceToomas Soome ranges;
199767f8919635c4928607450d9e0abb932109ceToomas Soome bus-frequency = <0>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome GIC: interrupt-controller@01c81000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "arm,gic";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c81000 0x1000>, /* Distributor Registers */
199767f8919635c4928607450d9e0abb932109ceToomas Soome <0x01c82000 0x0100>, /* CPU Interface Registers */
199767f8919635c4928607450d9e0abb932109ceToomas Soome <0x01c84000 0x2000>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <0x01c86000 0x2000>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-controller;
199767f8919635c4928607450d9e0abb932109ceToomas Soome #interrupt-cells = <3>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_PPI 9 (GIC_CPU_MASK_SIMPLE(4) | IRQ_TYPE_LEVEL_HIGH)>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome sramc@01c00000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun4i-sramc";
199767f8919635c4928607450d9e0abb932109ceToomas Soome #address-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome #size-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = < 0x01c00000 0x1000 >;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome cpu-cfg@01c25c00 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun7i-cpu-cfg";
199767f8919635c4928607450d9e0abb932109ceToomas Soome #address-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome #size-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = < 0x01c25c00 0x400 >;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome ccm@01c20000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun4i-ccm";
199767f8919635c4928607450d9e0abb932109ceToomas Soome #address-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome #size-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = < 0x01c20000 0x400 >;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome timer@01c20c00 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun4i-a10-timer";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c20c00 0x90>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 22 IRQ_TYPE_LEVEL_HIGH>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <GIC_SPI 23 IRQ_TYPE_LEVEL_HIGH>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <GIC_SPI 24 IRQ_TYPE_LEVEL_HIGH>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <GIC_SPI 25 IRQ_TYPE_LEVEL_HIGH>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <GIC_SPI 67 IRQ_TYPE_LEVEL_HIGH>,
199767f8919635c4928607450d9e0abb932109ceToomas Soome <GIC_SPI 68 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome clock-frequency = < 24000000 >;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome watchdog@01c20c90 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun4i-a10-wdt";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c20c90 0x10>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome pio: gpio@01c20800 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome #gpio-cells = <3>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun7i-a20-pinctrl";
199767f8919635c4928607450d9e0abb932109ceToomas Soome gpio-controller;
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg =< 0x01c20800 0x400 >;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 28 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-controller;
199767f8919635c4928607450d9e0abb932109ceToomas Soome #interrupt-cells = <2>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome gmac_pins_mii: gmac_mii@0 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome allwinner,pins = "PA0", "PA1", "PA2",
199767f8919635c4928607450d9e0abb932109ceToomas Soome "PA3", "PA4", "PA5", "PA6",
199767f8919635c4928607450d9e0abb932109ceToomas Soome "PA7", "PA8", "PA9", "PA10",
199767f8919635c4928607450d9e0abb932109ceToomas Soome "PA11", "PA12", "PA13", "PA14",
199767f8919635c4928607450d9e0abb932109ceToomas Soome "PA15", "PA16";
199767f8919635c4928607450d9e0abb932109ceToomas Soome allwinner,function = "gmac";
199767f8919635c4928607450d9e0abb932109ceToomas Soome allwinner,drive = <SUN4I_PINCTRL_10_MA>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome gmac_pins_rgmii: gmac_rgmii@0 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome allwinner,pins = "PA0", "PA1", "PA2",
199767f8919635c4928607450d9e0abb932109ceToomas Soome "PA3", "PA4", "PA5", "PA6",
199767f8919635c4928607450d9e0abb932109ceToomas Soome "PA7", "PA8", "PA10",
199767f8919635c4928607450d9e0abb932109ceToomas Soome "PA11", "PA12", "PA13",
199767f8919635c4928607450d9e0abb932109ceToomas Soome "PA15", "PA16";
199767f8919635c4928607450d9e0abb932109ceToomas Soome allwinner,function = "gmac";
199767f8919635c4928607450d9e0abb932109ceToomas Soome allwinner,drive = <SUN4I_PINCTRL_40_MA>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome usb1: usb@01c14000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun7i-a20-ehci", "generic-ehci";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c14000 0x1000>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 39 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome usb2: usb@01c1c000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun7i-a20-ehci", "generic-ehci";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c1c000 0x1000>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 40 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome mmc0: mmc@01c0f000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun5i-a13-mmc";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c0f000 0x1000>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 32 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome status = "disabled";
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome sata@01c18000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun4i-a10-ahci";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c18000 0x1000>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome status = "disabled";
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome UART0: serial@01c28000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "snps,dw-apb-uart";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c28000 0x400>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg-shift = <2>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 1 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome current-speed = <115200>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome clock-frequency = < 24000000 >;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome emac@01c0b000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun4i-a10-emac";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c0b000 0x1000>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome status = "disabled";
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome gmac@01c50000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun7i-a20-gmac";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c50000 0x10000>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <GIC_SPI 85 IRQ_TYPE_LEVEL_HIGH>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome snps,pbl = <2>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome snps,fixed-burst;
199767f8919635c4928607450d9e0abb932109ceToomas Soome snps,force_sf_dma_mode;
199767f8919635c4928607450d9e0abb932109ceToomas Soome status = "disabled";
199767f8919635c4928607450d9e0abb932109ceToomas Soome #address-cells = <1>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome #size-cells = <0>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome dma: dma-controller@01c02000 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun4i-a10-dma";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c02000 0x1000>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <27>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome
199767f8919635c4928607450d9e0abb932109ceToomas Soome codec: codec@01c22c00 {
199767f8919635c4928607450d9e0abb932109ceToomas Soome compatible = "allwinner,sun7i-a20-codec";
199767f8919635c4928607450d9e0abb932109ceToomas Soome reg = <0x01c22c00 0x40>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupts = <30>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome interrupt-parent = <&GIC>;
199767f8919635c4928607450d9e0abb932109ceToomas Soome status = "disabled";
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome };
199767f8919635c4928607450d9e0abb932109ceToomas Soome};
199767f8919635c4928607450d9e0abb932109ceToomas Soome