ARM: sunxi: dt: Add device tree for Mele A1000
authorEmilio López <emilio@elopez.com.ar>
Tue, 13 Aug 2013 23:18:21 +0000 (20:18 -0300)
committerMaxime Ripard <maxime.ripard@free-electrons.com>
Wed, 14 Aug 2013 07:59:20 +0000 (09:59 +0200)
This adds a device tree usable on Mele A1000 (and A2000, as it
apparently is the same device except for the case). This device features
one UART port, Ethernet, an AXP209 PMU on i2c0 and two user configurable
LEDs.

Signed-off-by: Emilio López <emilio@elopez.com.ar>
[maxime: fixed the soc node address]
Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
arch/arm/boot/dts/Makefile
arch/arm/boot/dts/sun4i-a10-a1000.dts [new file with mode: 0644]

index 641b3c9a7028c3368b5502c4a0f229c99327e521..3fd39193ef9153c5a45d3c6f5938a3d2747d5179 100644 (file)
@@ -206,6 +206,7 @@ dtb-$(CONFIG_ARCH_STI)+= stih415-b2000.dtb \
        stih415-b2020.dtb \
        stih416-b2020.dtb
 dtb-$(CONFIG_ARCH_SUNXI) += \
+       sun4i-a10-a1000.dtb \
        sun4i-a10-cubieboard.dtb \
        sun4i-a10-mini-xplus.dtb \
        sun4i-a10-hackberry.dtb \
diff --git a/arch/arm/boot/dts/sun4i-a10-a1000.dts b/arch/arm/boot/dts/sun4i-a10-a1000.dts
new file mode 100644 (file)
index 0000000..eb4d73b
--- /dev/null
@@ -0,0 +1,101 @@
+/*
+ * Copyright 2013 Emilio López
+ *
+ * Emilio López <emilio@elopez.com.ar>
+ *
+ * The code contained herein is licensed under the GNU General Public
+ * License. You may obtain a copy of the GNU General Public License
+ * Version 2 or later at the following locations:
+ *
+ * http://www.opensource.org/licenses/gpl-license.html
+ * http://www.gnu.org/copyleft/gpl.html
+ */
+
+/dts-v1/;
+/include/ "sun4i-a10.dtsi"
+
+/ {
+       model = "Mele A1000";
+       compatible = "mele,a1000", "allwinner,sun4i-a10";
+
+       aliases {
+               serial0 = &uart0;
+       };
+
+       soc@01c00000 {
+               emac: ethernet@01c0b000 {
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&emac_pins_a>;
+                       phy = <&phy1>;
+                       status = "okay";
+               };
+
+               mdio@01c0b080 {
+                       phy-supply = <&reg_emac_3v3>;
+                       status = "okay";
+
+                       phy1: ethernet-phy@1 {
+                               reg = <1>;
+                       };
+               };
+
+               pinctrl@01c20800 {
+                       emac_power_pin_a1000: emac_power_pin@0 {
+                               allwinner,pins = "PH15";
+                               allwinner,function = "gpio_out";
+                               allwinner,drive = <0>;
+                               allwinner,pull = <0>;
+                       };
+
+                       led_pins_a1000: led_pins@0 {
+                               allwinner,pins = "PH10", "PH20";
+                               allwinner,function = "gpio_out";
+                               allwinner,drive = <0>;
+                               allwinner,pull = <0>;
+                       };
+               };
+
+               uart0: serial@01c28000 {
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&uart0_pins_a>;
+                       status = "okay";
+               };
+
+               i2c0: i2c@01c2ac00 {
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&i2c0_pins_a>;
+                       status = "okay";
+               };
+       };
+
+       leds {
+               compatible = "gpio-leds";
+               pinctrl-names = "default";
+               pinctrl-0 = <&led_pins_a1000>;
+
+               red {
+                       label = "a1000:red:usr";
+                       gpios = <&pio 7 10 0>;
+               };
+
+               blue {
+                       label = "a1000:blue:usr";
+                       gpios = <&pio 7 20 0>;
+               };
+       };
+
+       regulators {
+               compatible = "simple-bus";
+
+               reg_emac_3v3: emac-3v3 {
+                       compatible = "regulator-fixed";
+                       pinctrl-names = "default";
+                       pinctrl-0 = <&emac_power_pin_a1000>;
+                       regulator-name = "emac-3v3";
+                       regulator-min-microvolt = <3300000>;
+                       regulator-max-microvolt = <3300000>;
+                       enable-active-high;
+                       gpio = <&pio 7 15 0>;
+               };
+       };
+};
This page took 0.028439 seconds and 5 git commands to generate.