153ab4af3SHans de Goede/* 253ab4af3SHans de Goede * Copyright 2012 Stefan Roese 353ab4af3SHans de Goede * Stefan Roese <sr@denx.de> 453ab4af3SHans de Goede * 553ab4af3SHans de Goede * This file is dual-licensed: you can use it either under the terms 653ab4af3SHans de Goede * of the GPL or the X11 license, at your option. Note that this dual 753ab4af3SHans de Goede * licensing only applies to this file, and not this project as a 853ab4af3SHans de Goede * whole. 953ab4af3SHans de Goede * 1053ab4af3SHans de Goede * a) This file is free software; you can redistribute it and/or 1153ab4af3SHans de Goede * modify it under the terms of the GNU General Public License as 1253ab4af3SHans de Goede * published by the Free Software Foundation; either version 2 of the 1353ab4af3SHans de Goede * License, or (at your option) any later version. 1453ab4af3SHans de Goede * 1553ab4af3SHans de Goede * This file is distributed in the hope that it will be useful, 1653ab4af3SHans de Goede * but WITHOUT ANY WARRANTY; without even the implied warranty of 1753ab4af3SHans de Goede * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 1853ab4af3SHans de Goede * GNU General Public License for more details. 1953ab4af3SHans de Goede * 2053ab4af3SHans de Goede * Or, alternatively, 2153ab4af3SHans de Goede * 2253ab4af3SHans de Goede * b) Permission is hereby granted, free of charge, to any person 2353ab4af3SHans de Goede * obtaining a copy of this software and associated documentation 2453ab4af3SHans de Goede * files (the "Software"), to deal in the Software without 2553ab4af3SHans de Goede * restriction, including without limitation the rights to use, 2653ab4af3SHans de Goede * copy, modify, merge, publish, distribute, sublicense, and/or 2753ab4af3SHans de Goede * sell copies of the Software, and to permit persons to whom the 2853ab4af3SHans de Goede * Software is furnished to do so, subject to the following 2953ab4af3SHans de Goede * conditions: 3053ab4af3SHans de Goede * 3153ab4af3SHans de Goede * The above copyright notice and this permission notice shall be 3253ab4af3SHans de Goede * included in all copies or substantial portions of the Software. 3353ab4af3SHans de Goede * 3453ab4af3SHans de Goede * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 3553ab4af3SHans de Goede * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 3653ab4af3SHans de Goede * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 3753ab4af3SHans de Goede * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 3853ab4af3SHans de Goede * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 3953ab4af3SHans de Goede * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 4053ab4af3SHans de Goede * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 4153ab4af3SHans de Goede * OTHER DEALINGS IN THE SOFTWARE. 4253ab4af3SHans de Goede */ 4353ab4af3SHans de Goede 4453ab4af3SHans de Goede/dts-v1/; 4553ab4af3SHans de Goede#include "sun4i-a10.dtsi" 4653ab4af3SHans de Goede#include "sunxi-common-regulators.dtsi" 4753ab4af3SHans de Goede 4853ab4af3SHans de Goede#include <dt-bindings/gpio/gpio.h> 4953ab4af3SHans de Goede 5053ab4af3SHans de Goede/ { 5153ab4af3SHans de Goede model = "Cubietech Cubieboard"; 5253ab4af3SHans de Goede compatible = "cubietech,a10-cubieboard", "allwinner,sun4i-a10"; 5353ab4af3SHans de Goede 5453ab4af3SHans de Goede aliases { 5553ab4af3SHans de Goede serial0 = &uart0; 5653ab4af3SHans de Goede }; 5753ab4af3SHans de Goede 5853ab4af3SHans de Goede chosen { 5953ab4af3SHans de Goede stdout-path = "serial0:115200n8"; 6053ab4af3SHans de Goede }; 6153ab4af3SHans de Goede 62*3c92cca3SJagan Teki hdmi-connector { 63*3c92cca3SJagan Teki compatible = "hdmi-connector"; 64*3c92cca3SJagan Teki type = "a"; 65*3c92cca3SJagan Teki 66*3c92cca3SJagan Teki port { 67*3c92cca3SJagan Teki hdmi_con_in: endpoint { 68*3c92cca3SJagan Teki remote-endpoint = <&hdmi_out_con>; 69*3c92cca3SJagan Teki }; 70*3c92cca3SJagan Teki }; 71*3c92cca3SJagan Teki }; 72*3c92cca3SJagan Teki 7353ab4af3SHans de Goede leds { 7453ab4af3SHans de Goede compatible = "gpio-leds"; 7553ab4af3SHans de Goede pinctrl-names = "default"; 7653ab4af3SHans de Goede pinctrl-0 = <&led_pins_cubieboard>; 7753ab4af3SHans de Goede 7853ab4af3SHans de Goede blue { 7953ab4af3SHans de Goede label = "cubieboard:blue:usr"; 8053ab4af3SHans de Goede gpios = <&pio 7 21 GPIO_ACTIVE_HIGH>; /* LED1 */ 8153ab4af3SHans de Goede }; 8253ab4af3SHans de Goede 8353ab4af3SHans de Goede green { 8453ab4af3SHans de Goede label = "cubieboard:green:usr"; 8553ab4af3SHans de Goede gpios = <&pio 7 20 GPIO_ACTIVE_HIGH>; /* LED2 */ 8653ab4af3SHans de Goede linux,default-trigger = "heartbeat"; 8753ab4af3SHans de Goede }; 8853ab4af3SHans de Goede }; 8953ab4af3SHans de Goede}; 9053ab4af3SHans de Goede 9153ab4af3SHans de Goede&ahci { 9253ab4af3SHans de Goede target-supply = <®_ahci_5v>; 9353ab4af3SHans de Goede status = "okay"; 9453ab4af3SHans de Goede}; 9553ab4af3SHans de Goede 9680e5f83cSHans de Goede&codec { 9780e5f83cSHans de Goede status = "okay"; 9880e5f83cSHans de Goede}; 9980e5f83cSHans de Goede 10053ab4af3SHans de Goede&cpu0 { 10153ab4af3SHans de Goede cpu-supply = <®_dcdc2>; 10253ab4af3SHans de Goede}; 10353ab4af3SHans de Goede 104*3c92cca3SJagan Teki&de { 105*3c92cca3SJagan Teki status = "okay"; 106*3c92cca3SJagan Teki}; 107*3c92cca3SJagan Teki 10853ab4af3SHans de Goede&ehci0 { 10953ab4af3SHans de Goede status = "okay"; 11053ab4af3SHans de Goede}; 11153ab4af3SHans de Goede 11253ab4af3SHans de Goede&ehci1 { 11353ab4af3SHans de Goede status = "okay"; 11453ab4af3SHans de Goede}; 11553ab4af3SHans de Goede 11653ab4af3SHans de Goede&emac { 11753ab4af3SHans de Goede phy = <&phy1>; 11853ab4af3SHans de Goede status = "okay"; 11953ab4af3SHans de Goede}; 12053ab4af3SHans de Goede 1218b1ba941SHans de Goede&emac_sram { 1228b1ba941SHans de Goede status = "okay"; 1238b1ba941SHans de Goede}; 1248b1ba941SHans de Goede 125*3c92cca3SJagan Teki&hdmi { 126*3c92cca3SJagan Teki status = "okay"; 127*3c92cca3SJagan Teki}; 128*3c92cca3SJagan Teki 129*3c92cca3SJagan Teki&hdmi_out { 130*3c92cca3SJagan Teki hdmi_out_con: endpoint { 131*3c92cca3SJagan Teki remote-endpoint = <&hdmi_con_in>; 132*3c92cca3SJagan Teki }; 133*3c92cca3SJagan Teki}; 134*3c92cca3SJagan Teki 13553ab4af3SHans de Goede&i2c0 { 13653ab4af3SHans de Goede status = "okay"; 13753ab4af3SHans de Goede 13853ab4af3SHans de Goede axp209: pmic@34 { 13953ab4af3SHans de Goede reg = <0x34>; 14053ab4af3SHans de Goede interrupts = <0>; 14153ab4af3SHans de Goede }; 14253ab4af3SHans de Goede}; 14353ab4af3SHans de Goede 14453ab4af3SHans de Goede&i2c1 { 14553ab4af3SHans de Goede status = "okay"; 14653ab4af3SHans de Goede}; 14753ab4af3SHans de Goede 14853ab4af3SHans de Goede&ir0 { 14953ab4af3SHans de Goede pinctrl-names = "default"; 150*3c92cca3SJagan Teki pinctrl-0 = <&ir0_rx_pins>; 15153ab4af3SHans de Goede status = "okay"; 15253ab4af3SHans de Goede}; 15353ab4af3SHans de Goede 15453ab4af3SHans de Goede&mdio { 15553ab4af3SHans de Goede status = "okay"; 15653ab4af3SHans de Goede 15753ab4af3SHans de Goede phy1: ethernet-phy@1 { 15853ab4af3SHans de Goede reg = <1>; 15953ab4af3SHans de Goede }; 16053ab4af3SHans de Goede}; 16153ab4af3SHans de Goede 16253ab4af3SHans de Goede&mmc0 { 16353ab4af3SHans de Goede vmmc-supply = <®_vcc3v3>; 16453ab4af3SHans de Goede bus-width = <4>; 165*3c92cca3SJagan Teki cd-gpios = <&pio 7 1 GPIO_ACTIVE_LOW>; /* PH1 */ 16653ab4af3SHans de Goede status = "okay"; 16753ab4af3SHans de Goede}; 16853ab4af3SHans de Goede 16953ab4af3SHans de Goede&ohci0 { 17053ab4af3SHans de Goede status = "okay"; 17153ab4af3SHans de Goede}; 17253ab4af3SHans de Goede 17353ab4af3SHans de Goede&ohci1 { 17453ab4af3SHans de Goede status = "okay"; 17553ab4af3SHans de Goede}; 17653ab4af3SHans de Goede 177da52a4a3SHans de Goede&otg_sram { 178da52a4a3SHans de Goede status = "okay"; 179da52a4a3SHans de Goede}; 180da52a4a3SHans de Goede 18153ab4af3SHans de Goede&pio { 182*3c92cca3SJagan Teki led_pins_cubieboard: led-pins { 183*3c92cca3SJagan Teki pins = "PH20", "PH21"; 184*3c92cca3SJagan Teki function = "gpio_out"; 185*3c92cca3SJagan Teki drive-strength = <20>; 18653ab4af3SHans de Goede }; 187da52a4a3SHans de Goede 188*3c92cca3SJagan Teki usb0_id_detect_pin: usb0-id-detect-pin { 189*3c92cca3SJagan Teki pins = "PH4"; 190*3c92cca3SJagan Teki function = "gpio_in"; 191*3c92cca3SJagan Teki bias-pull-up; 192da52a4a3SHans de Goede }; 19353ab4af3SHans de Goede}; 19453ab4af3SHans de Goede 19553ab4af3SHans de Goede®_ahci_5v { 19653ab4af3SHans de Goede status = "okay"; 19753ab4af3SHans de Goede}; 19853ab4af3SHans de Goede 19953ab4af3SHans de Goede#include "axp209.dtsi" 20053ab4af3SHans de Goede 201*3c92cca3SJagan Teki&ac_power_supply { 202*3c92cca3SJagan Teki status = "okay"; 203*3c92cca3SJagan Teki}; 204*3c92cca3SJagan Teki 20553ab4af3SHans de Goede®_dcdc2 { 20653ab4af3SHans de Goede regulator-always-on; 20753ab4af3SHans de Goede regulator-min-microvolt = <1000000>; 20853ab4af3SHans de Goede regulator-max-microvolt = <1450000>; 20953ab4af3SHans de Goede regulator-name = "vdd-cpu"; 21053ab4af3SHans de Goede}; 21153ab4af3SHans de Goede 21253ab4af3SHans de Goede®_dcdc3 { 21353ab4af3SHans de Goede regulator-always-on; 21453ab4af3SHans de Goede regulator-min-microvolt = <1000000>; 21553ab4af3SHans de Goede regulator-max-microvolt = <1400000>; 21653ab4af3SHans de Goede regulator-name = "vdd-int-dll"; 21753ab4af3SHans de Goede}; 21853ab4af3SHans de Goede 21953ab4af3SHans de Goede®_ldo1 { 22053ab4af3SHans de Goede regulator-name = "vdd-rtc"; 22153ab4af3SHans de Goede}; 22253ab4af3SHans de Goede 22353ab4af3SHans de Goede®_ldo2 { 22453ab4af3SHans de Goede regulator-always-on; 22553ab4af3SHans de Goede regulator-min-microvolt = <3000000>; 22653ab4af3SHans de Goede regulator-max-microvolt = <3000000>; 22753ab4af3SHans de Goede regulator-name = "avcc"; 22853ab4af3SHans de Goede}; 22953ab4af3SHans de Goede 23053ab4af3SHans de Goede®_usb1_vbus { 23153ab4af3SHans de Goede status = "okay"; 23253ab4af3SHans de Goede}; 23353ab4af3SHans de Goede 23453ab4af3SHans de Goede®_usb2_vbus { 23553ab4af3SHans de Goede status = "okay"; 23653ab4af3SHans de Goede}; 23753ab4af3SHans de Goede 23853ab4af3SHans de Goede&spi0 { 23953ab4af3SHans de Goede pinctrl-names = "default"; 240*3c92cca3SJagan Teki pinctrl-0 = <&spi0_pi_pins>, 241*3c92cca3SJagan Teki <&spi0_cs0_pi_pin>; 24253ab4af3SHans de Goede status = "okay"; 24353ab4af3SHans de Goede}; 24453ab4af3SHans de Goede 24553ab4af3SHans de Goede&uart0 { 24653ab4af3SHans de Goede pinctrl-names = "default"; 247*3c92cca3SJagan Teki pinctrl-0 = <&uart0_pb_pins>; 24853ab4af3SHans de Goede status = "okay"; 24953ab4af3SHans de Goede}; 25053ab4af3SHans de Goede 251da52a4a3SHans de Goede&usb_otg { 252da52a4a3SHans de Goede dr_mode = "otg"; 253da52a4a3SHans de Goede status = "okay"; 254da52a4a3SHans de Goede}; 255da52a4a3SHans de Goede 25653ab4af3SHans de Goede&usbphy { 257da52a4a3SHans de Goede pinctrl-names = "default"; 258da52a4a3SHans de Goede pinctrl-0 = <&usb0_id_detect_pin>; 259da52a4a3SHans de Goede usb0_id_det-gpio = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */ 26053ab4af3SHans de Goede usb1_vbus-supply = <®_usb1_vbus>; 26153ab4af3SHans de Goede usb2_vbus-supply = <®_usb2_vbus>; 26253ab4af3SHans de Goede status = "okay"; 26353ab4af3SHans de Goede}; 264