Merge tag 'bcm5301x-dt-2014-12-04' of https://github.com/hauke/linux into next/dt
[cascardo/linux.git] / arch / arm / boot / dts / sun4i-a10-cubieboard.dts
1 /*
2  * Copyright 2012 Stefan Roese
3  * Stefan Roese <sr@denx.de>
4  *
5  * This file is dual-licensed: you can use it either under the terms
6  * of the GPL or the X11 license, at your option. Note that this dual
7  * licensing only applies to this file, and not this project as a
8  * whole.
9  *
10  *  a) This file is free software; you can redistribute it and/or
11  *     modify it under the terms of the GNU General Public License as
12  *     published by the Free Software Foundation; either version 2 of the
13  *     License, or (at your option) any later version.
14  *
15  *     This file is distributed in the hope that it will be useful,
16  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
17  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  *     GNU General Public License for more details.
19  *
20  *     You should have received a copy of the GNU General Public
21  *     License along with this file; if not, write to the Free
22  *     Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
23  *     MA 02110-1301 USA
24  *
25  * Or, alternatively,
26  *
27  *  b) Permission is hereby granted, free of charge, to any person
28  *     obtaining a copy of this software and associated documentation
29  *     files (the "Software"), to deal in the Software without
30  *     restriction, including without limitation the rights to use,
31  *     copy, modify, merge, publish, distribute, sublicense, and/or
32  *     sell copies of the Software, and to permit persons to whom the
33  *     Software is furnished to do so, subject to the following
34  *     conditions:
35  *
36  *     The above copyright notice and this permission notice shall be
37  *     included in all copies or substantial portions of the Software.
38  *
39  *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
40  *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
41  *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
42  *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
43  *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
44  *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
45  *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
46  *     OTHER DEALINGS IN THE SOFTWARE.
47  */
48
49 /dts-v1/;
50 /include/ "sun4i-a10.dtsi"
51 /include/ "sunxi-common-regulators.dtsi"
52
53 / {
54         model = "Cubietech Cubieboard";
55         compatible = "cubietech,a10-cubieboard", "allwinner,sun4i-a10";
56
57         soc@01c00000 {
58                 emac: ethernet@01c0b000 {
59                         pinctrl-names = "default";
60                         pinctrl-0 = <&emac_pins_a>;
61                         phy = <&phy1>;
62                         status = "okay";
63                 };
64
65                 mdio@01c0b080 {
66                         status = "okay";
67
68                         phy1: ethernet-phy@1 {
69                                 reg = <1>;
70                         };
71                 };
72
73                 mmc0: mmc@01c0f000 {
74                         pinctrl-names = "default";
75                         pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>;
76                         vmmc-supply = <&reg_vcc3v3>;
77                         bus-width = <4>;
78                         cd-gpios = <&pio 7 1 0>; /* PH1 */
79                         cd-inverted;
80                         status = "okay";
81                 };
82
83                 usbphy: phy@01c13400 {
84                         usb1_vbus-supply = <&reg_usb1_vbus>;
85                         usb2_vbus-supply = <&reg_usb2_vbus>;
86                         status = "okay";
87                 };
88
89                 ehci0: usb@01c14000 {
90                         status = "okay";
91                 };
92
93                 ohci0: usb@01c14400 {
94                         status = "okay";
95                 };
96
97                 ahci: sata@01c18000 {
98                         target-supply = <&reg_ahci_5v>;
99                         status = "okay";
100                 };
101
102                 ehci1: usb@01c1c000 {
103                         status = "okay";
104                 };
105
106                 ohci1: usb@01c1c400 {
107                         status = "okay";
108                 };
109
110                 pinctrl@01c20800 {
111                         led_pins_cubieboard: led_pins@0 {
112                                 allwinner,pins = "PH20", "PH21";
113                                 allwinner,function = "gpio_out";
114                                 allwinner,drive = <1>;
115                                 allwinner,pull = <0>;
116                         };
117                 };
118
119                 ir0: ir@01c21800 {
120                         pinctrl-names = "default";
121                         pinctrl-0 = <&ir0_pins_a>;
122                         status = "okay";
123                 };
124
125                 uart0: serial@01c28000 {
126                         pinctrl-names = "default";
127                         pinctrl-0 = <&uart0_pins_a>;
128                         status = "okay";
129                 };
130
131                 i2c0: i2c@01c2ac00 {
132                         pinctrl-names = "default";
133                         pinctrl-0 = <&i2c0_pins_a>;
134                         status = "okay";
135
136                         axp209: pmic@34 {
137                                 compatible = "x-powers,axp209";
138                                 reg = <0x34>;
139                                 interrupts = <0>;
140
141                                 interrupt-controller;
142                                 #interrupt-cells = <1>;
143                         };
144                 };
145
146                 i2c1: i2c@01c2b000 {
147                         pinctrl-names = "default";
148                         pinctrl-0 = <&i2c1_pins_a>;
149                         status = "okay";
150                 };
151         };
152
153         leds {
154                 compatible = "gpio-leds";
155                 pinctrl-names = "default";
156                 pinctrl-0 = <&led_pins_cubieboard>;
157
158                 blue {
159                         label = "cubieboard:blue:usr";
160                         gpios = <&pio 7 21 0>; /* LED1 */
161                 };
162
163                 green {
164                         label = "cubieboard:green:usr";
165                         gpios = <&pio 7 20 0>; /* LED2 */
166                         linux,default-trigger = "heartbeat";
167                 };
168         };
169
170         reg_ahci_5v: ahci-5v {
171                 status = "okay";
172         };
173
174         reg_usb1_vbus: usb1-vbus {
175                 status = "okay";
176         };
177
178         reg_usb2_vbus: usb2-vbus {
179                 status = "okay";
180         };
181 };