1*53ab4af3SHans de Goede/* 2*53ab4af3SHans de Goede * Copyright 2015 Aleksei Mamlin 3*53ab4af3SHans de Goede * Aleksei Mamlin <mamlinav@gmail.com> 4*53ab4af3SHans de Goede * 5*53ab4af3SHans de Goede * This file is dual-licensed: you can use it either under the terms 6*53ab4af3SHans de Goede * of the GPL or the X11 license, at your option. Note that this dual 7*53ab4af3SHans de Goede * licensing only applies to this file, and not this project as a 8*53ab4af3SHans de Goede * whole. 9*53ab4af3SHans de Goede * 10*53ab4af3SHans de Goede * a) This file is free software; you can redistribute it and/or 11*53ab4af3SHans de Goede * modify it under the terms of the GNU General Public License as 12*53ab4af3SHans de Goede * published by the Free Software Foundation; either version 2 of the 13*53ab4af3SHans de Goede * License, or (at your option) any later version. 14*53ab4af3SHans de Goede * 15*53ab4af3SHans de Goede * This file is distributed in the hope that it will be useful, 16*53ab4af3SHans de Goede * but WITHOUT ANY WARRANTY; without even the implied warranty of 17*53ab4af3SHans de Goede * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18*53ab4af3SHans de Goede * GNU General Public License for more details. 19*53ab4af3SHans de Goede * 20*53ab4af3SHans de Goede * You should have received a copy of the GNU General Public 21*53ab4af3SHans de Goede * License along with this file; if not, write to the Free 22*53ab4af3SHans de Goede * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, 23*53ab4af3SHans de Goede * MA 02110-1301 USA 24*53ab4af3SHans de Goede * 25*53ab4af3SHans de Goede * Or, alternatively, 26*53ab4af3SHans de Goede * 27*53ab4af3SHans de Goede * b) Permission is hereby granted, free of charge, to any person 28*53ab4af3SHans de Goede * obtaining a copy of this software and associated documentation 29*53ab4af3SHans de Goede * files (the "Software"), to deal in the Software without 30*53ab4af3SHans de Goede * restriction, including without limitation the rights to use, 31*53ab4af3SHans de Goede * copy, modify, merge, publish, distribute, sublicense, and/or 32*53ab4af3SHans de Goede * sell copies of the Software, and to permit persons to whom the 33*53ab4af3SHans de Goede * Software is furnished to do so, subject to the following 34*53ab4af3SHans de Goede * conditions: 35*53ab4af3SHans de Goede * 36*53ab4af3SHans de Goede * The above copyright notice and this permission notice shall be 37*53ab4af3SHans de Goede * included in all copies or substantial portions of the Software. 38*53ab4af3SHans de Goede * 39*53ab4af3SHans de Goede * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 40*53ab4af3SHans de Goede * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 41*53ab4af3SHans de Goede * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 42*53ab4af3SHans de Goede * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 43*53ab4af3SHans de Goede * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 44*53ab4af3SHans de Goede * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 45*53ab4af3SHans de Goede * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 46*53ab4af3SHans de Goede * OTHER DEALINGS IN THE SOFTWARE. 47*53ab4af3SHans de Goede */ 48*53ab4af3SHans de Goede 49*53ab4af3SHans de Goede/dts-v1/; 50*53ab4af3SHans de Goede#include "sun4i-a10.dtsi" 51*53ab4af3SHans de Goede#include "sunxi-common-regulators.dtsi" 52*53ab4af3SHans de Goede 53*53ab4af3SHans de Goede#include <dt-bindings/gpio/gpio.h> 54*53ab4af3SHans de Goede#include <dt-bindings/pinctrl/sun4i-a10.h> 55*53ab4af3SHans de Goede 56*53ab4af3SHans de Goede/ { 57*53ab4af3SHans de Goede model = "HAOYU Electronics Marsboard A10"; 58*53ab4af3SHans de Goede compatible = "haoyu,a10-marsboard", "allwinner,sun4i-a10"; 59*53ab4af3SHans de Goede 60*53ab4af3SHans de Goede aliases { 61*53ab4af3SHans de Goede serial0 = &uart0; 62*53ab4af3SHans de Goede }; 63*53ab4af3SHans de Goede 64*53ab4af3SHans de Goede chosen { 65*53ab4af3SHans de Goede stdout-path = "serial0:115200n8"; 66*53ab4af3SHans de Goede }; 67*53ab4af3SHans de Goede 68*53ab4af3SHans de Goede leds { 69*53ab4af3SHans de Goede compatible = "gpio-leds"; 70*53ab4af3SHans de Goede pinctrl-names = "default"; 71*53ab4af3SHans de Goede pinctrl-0 = <&led_pins_marsboard>; 72*53ab4af3SHans de Goede 73*53ab4af3SHans de Goede red1 { 74*53ab4af3SHans de Goede label = "marsboard:red1:usr"; 75*53ab4af3SHans de Goede gpios = <&pio 1 5 GPIO_ACTIVE_HIGH>; 76*53ab4af3SHans de Goede }; 77*53ab4af3SHans de Goede 78*53ab4af3SHans de Goede red2 { 79*53ab4af3SHans de Goede label = "marsboard:red2:usr"; 80*53ab4af3SHans de Goede gpios = <&pio 1 6 GPIO_ACTIVE_HIGH>; 81*53ab4af3SHans de Goede }; 82*53ab4af3SHans de Goede 83*53ab4af3SHans de Goede red3 { 84*53ab4af3SHans de Goede label = "marsboard:red3:usr"; 85*53ab4af3SHans de Goede gpios = <&pio 1 7 GPIO_ACTIVE_HIGH>; 86*53ab4af3SHans de Goede }; 87*53ab4af3SHans de Goede 88*53ab4af3SHans de Goede red4 { 89*53ab4af3SHans de Goede label = "marsboard:red4:usr"; 90*53ab4af3SHans de Goede gpios = <&pio 1 8 GPIO_ACTIVE_HIGH>; 91*53ab4af3SHans de Goede }; 92*53ab4af3SHans de Goede }; 93*53ab4af3SHans de Goede}; 94*53ab4af3SHans de Goede 95*53ab4af3SHans de Goede&ahci { 96*53ab4af3SHans de Goede status = "okay"; 97*53ab4af3SHans de Goede}; 98*53ab4af3SHans de Goede 99*53ab4af3SHans de Goede&ehci0 { 100*53ab4af3SHans de Goede status = "okay"; 101*53ab4af3SHans de Goede}; 102*53ab4af3SHans de Goede 103*53ab4af3SHans de Goede&ehci1 { 104*53ab4af3SHans de Goede status = "okay"; 105*53ab4af3SHans de Goede}; 106*53ab4af3SHans de Goede 107*53ab4af3SHans de Goede&emac { 108*53ab4af3SHans de Goede pinctrl-names = "default"; 109*53ab4af3SHans de Goede pinctrl-0 = <&emac_pins_a>; 110*53ab4af3SHans de Goede phy = <&phy1>; 111*53ab4af3SHans de Goede status = "okay"; 112*53ab4af3SHans de Goede}; 113*53ab4af3SHans de Goede 114*53ab4af3SHans de Goede&i2c0 { 115*53ab4af3SHans de Goede pinctrl-names = "default"; 116*53ab4af3SHans de Goede pinctrl-0 = <&i2c0_pins_a>; 117*53ab4af3SHans de Goede status = "okay"; 118*53ab4af3SHans de Goede}; 119*53ab4af3SHans de Goede 120*53ab4af3SHans de Goede&i2c1 { 121*53ab4af3SHans de Goede pinctrl-names = "default"; 122*53ab4af3SHans de Goede pinctrl-0 = <&i2c1_pins_a>; 123*53ab4af3SHans de Goede status = "okay"; 124*53ab4af3SHans de Goede}; 125*53ab4af3SHans de Goede 126*53ab4af3SHans de Goede&i2c2 { 127*53ab4af3SHans de Goede pinctrl-names = "default"; 128*53ab4af3SHans de Goede pinctrl-0 = <&i2c2_pins_a>; 129*53ab4af3SHans de Goede status = "okay"; 130*53ab4af3SHans de Goede}; 131*53ab4af3SHans de Goede 132*53ab4af3SHans de Goede&mdio { 133*53ab4af3SHans de Goede status = "okay"; 134*53ab4af3SHans de Goede 135*53ab4af3SHans de Goede phy1: ethernet-phy@1 { 136*53ab4af3SHans de Goede reg = <1>; 137*53ab4af3SHans de Goede }; 138*53ab4af3SHans de Goede}; 139*53ab4af3SHans de Goede 140*53ab4af3SHans de Goede&mmc0 { 141*53ab4af3SHans de Goede pinctrl-names = "default"; 142*53ab4af3SHans de Goede pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>; 143*53ab4af3SHans de Goede vmmc-supply = <®_vcc3v3>; 144*53ab4af3SHans de Goede bus-width = <4>; 145*53ab4af3SHans de Goede cd-gpios = <&pio 7 1 GPIO_ACTIVE_HIGH>; /* PH1 */ 146*53ab4af3SHans de Goede cd-inverted; 147*53ab4af3SHans de Goede status = "okay"; 148*53ab4af3SHans de Goede}; 149*53ab4af3SHans de Goede 150*53ab4af3SHans de Goede&ohci0 { 151*53ab4af3SHans de Goede status = "okay"; 152*53ab4af3SHans de Goede}; 153*53ab4af3SHans de Goede 154*53ab4af3SHans de Goede&ohci1 { 155*53ab4af3SHans de Goede status = "okay"; 156*53ab4af3SHans de Goede}; 157*53ab4af3SHans de Goede 158*53ab4af3SHans de Goede&pio { 159*53ab4af3SHans de Goede led_pins_marsboard: led_pins@0 { 160*53ab4af3SHans de Goede allwinner,pins = "PB5", "PB6", "PB7", "PB8"; 161*53ab4af3SHans de Goede allwinner,function = "gpio_out"; 162*53ab4af3SHans de Goede allwinner,drive = <SUN4I_PINCTRL_10_MA>; 163*53ab4af3SHans de Goede allwinner,pull = <SUN4I_PINCTRL_NO_PULL>; 164*53ab4af3SHans de Goede }; 165*53ab4af3SHans de Goede}; 166*53ab4af3SHans de Goede 167*53ab4af3SHans de Goede®_usb1_vbus { 168*53ab4af3SHans de Goede status = "okay"; 169*53ab4af3SHans de Goede}; 170*53ab4af3SHans de Goede 171*53ab4af3SHans de Goede®_usb2_vbus { 172*53ab4af3SHans de Goede status = "okay"; 173*53ab4af3SHans de Goede}; 174*53ab4af3SHans de Goede 175*53ab4af3SHans de Goede&spi0 { 176*53ab4af3SHans de Goede pinctrl-names = "default"; 177*53ab4af3SHans de Goede pinctrl-0 = <&spi0_pins_a>; 178*53ab4af3SHans de Goede status = "okay"; 179*53ab4af3SHans de Goede}; 180*53ab4af3SHans de Goede 181*53ab4af3SHans de Goede&uart0 { 182*53ab4af3SHans de Goede pinctrl-names = "default"; 183*53ab4af3SHans de Goede pinctrl-0 = <&uart0_pins_a>; 184*53ab4af3SHans de Goede status = "okay"; 185*53ab4af3SHans de Goede}; 186*53ab4af3SHans de Goede 187*53ab4af3SHans de Goede&usbphy { 188*53ab4af3SHans de Goede usb1_vbus-supply = <®_usb1_vbus>; 189*53ab4af3SHans de Goede usb2_vbus-supply = <®_usb2_vbus>; 190*53ab4af3SHans de Goede status = "okay"; 191*53ab4af3SHans de Goede}; 192