]> git.kernelconcepts.de Git - karo-tx-linux.git/blob - arch/arm/boot/dts/sun5i-a13-utoo-p66.dts
ARM: at91/dt: sama5d4: fix broken arithmetic expression in dmas property of i2c1
[karo-tx-linux.git] / arch / arm / boot / dts / sun5i-a13-utoo-p66.dts
1 /*
2  * Copyright 2015 Hans de Goede <hdegoede@redhat.com>
3  *
4  * This file is dual-licensed: you can use it either under the terms
5  * of the GPL or the X11 license, at your option. Note that this dual
6  * licensing only applies to this file, and not this project as a
7  * whole.
8  *
9  *  a) This file is free software; you can redistribute it and/or
10  *     modify it under the terms of the GNU General Public License as
11  *     published by the Free Software Foundation; either version 2 of the
12  *     License, or (at your option) any later version.
13  *
14  *     This file is distributed in the hope that it will be useful,
15  *     but WITHOUT ANY WARRANTY; without even the implied warranty of
16  *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  *     GNU General Public License for more details.
18  *
19  *     You should have received a copy of the GNU General Public
20  *     License along with this file; if not, write to the Free
21  *     Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
22  *     MA 02110-1301 USA
23  *
24  * Or, alternatively,
25  *
26  *  b) Permission is hereby granted, free of charge, to any person
27  *     obtaining a copy of this software and associated documentation
28  *     files (the "Software"), to deal in the Software without
29  *     restriction, including without limitation the rights to use,
30  *     copy, modify, merge, publish, distribute, sublicense, and/or
31  *     sell copies of the Software, and to permit persons to whom the
32  *     Software is furnished to do so, subject to the following
33  *     conditions:
34  *
35  *     The above copyright notice and this permission notice shall be
36  *     included in all copies or substantial portions of the Software.
37  *
38  *     THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
39  *     EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
40  *     OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
41  *     NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
42  *     HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
43  *     WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
44  *     FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
45  *     OTHER DEALINGS IN THE SOFTWARE.
46  */
47
48 /dts-v1/;
49 #include "sun5i-a13.dtsi"
50 #include "sunxi-common-regulators.dtsi"
51 #include <dt-bindings/gpio/gpio.h>
52 #include <dt-bindings/input/input.h>
53 #include <dt-bindings/pinctrl/sun4i-a10.h>
54
55 / {
56         model = "Utoo P66";
57         compatible = "utoo,p66", "allwinner,sun5i-a13";
58
59         i2c_lcd: i2c@0 {
60                 /* The lcd panel i2c interface is hooked up via gpios */
61                 compatible = "i2c-gpio";
62                 pinctrl-names = "default";
63                 pinctrl-0 = <&i2c_lcd_pins>;
64                 gpios = <&pio 6 12 GPIO_ACTIVE_HIGH>, /* PG12, sda */
65                         <&pio 6 10 GPIO_ACTIVE_HIGH>; /* PG10, scl */
66                 i2c-gpio,delay-us = <5>;
67         };
68 };
69
70 &cpu0 {
71         cpu-supply = <&reg_dcdc2>;
72 };
73
74 &ehci0 {
75         status = "okay";
76 };
77
78 &i2c0 {
79         pinctrl-names = "default";
80         pinctrl-0 = <&i2c0_pins_a>;
81         status = "okay";
82
83         axp209: pmic@34 {
84                 reg = <0x34>;
85                 interrupts = <0>;
86         };
87 };
88
89 #include "axp209.dtsi"
90
91 &i2c1 {
92         pinctrl-names = "default";
93         pinctrl-0 = <&i2c1_pins_a>;
94         status = "okay";
95
96         pcf8563: rtc@51 {
97                 compatible = "nxp,pcf8563";
98                 reg = <0x51>;
99         };
100 };
101
102 &lradc {
103         vref-supply = <&reg_ldo2>;
104         status = "okay";
105
106         button@200 {
107                 label = "Volume Up";
108                 linux,code = <KEY_VOLUMEUP>;
109                 channel = <0>;
110                 voltage = <200000>;
111         };
112
113         button@400 {
114                 label = "Volume Down";
115                 linux,code = <KEY_VOLUMEDOWN>;
116                 channel = <0>;
117                 voltage = <400000>;
118         };
119 };
120
121 &mmc0 {
122         pinctrl-names = "default";
123         pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_p66>;
124         vmmc-supply = <&reg_vcc3v3>;
125         bus-width = <4>;
126         cd-gpios = <&pio 6 0 GPIO_ACTIVE_HIGH>; /* PG0 */
127         cd-inverted;
128         status = "okay";
129 };
130
131 &mmc2 {
132         pinctrl-names = "default";
133         pinctrl-0 = <&mmc2_pins_a>;
134         vmmc-supply = <&reg_vcc3v3>;
135         bus-width = <8>;
136         non-removable;
137         status = "okay";
138 };
139
140 &pio {
141         mmc0_cd_pin_p66: mmc0_cd_pin@0 {
142                 allwinner,pins = "PG0";
143                 allwinner,function = "gpio_in";
144                 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
145                 allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
146         };
147
148         i2c_lcd_pins: i2c_lcd_pin@0 {
149                 allwinner,pins = "PG10", "PG12";
150                 allwinner,function = "gpio_out";
151                 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
152                 allwinner,pull = <SUN4I_PINCTRL_PULL_UP>;
153         };
154
155         usb0_vbus_pin_a: usb0_vbus_pin@0 {
156                 allwinner,pins = "PB4";
157                 allwinner,function = "gpio_out";
158                 allwinner,drive = <SUN4I_PINCTRL_10_MA>;
159                 allwinner,pull = <SUN4I_PINCTRL_NO_PULL>;
160         };
161 };
162
163 &reg_dcdc2 {
164         regulator-always-on;
165         regulator-min-microvolt = <1000000>;
166         regulator-max-microvolt = <1500000>;
167         regulator-name = "vdd-cpu";
168 };
169
170 &reg_dcdc3 {
171         regulator-always-on;
172         regulator-min-microvolt = <1000000>;
173         regulator-max-microvolt = <1400000>;
174         regulator-name = "vdd-int-pll";
175 };
176
177 &reg_ldo1 {
178         regulator-name = "vdd-rtc";
179 };
180
181 &reg_ldo2 {
182         regulator-always-on;
183         regulator-min-microvolt = <3000000>;
184         regulator-max-microvolt = <3000000>;
185         regulator-name = "avcc";
186 };
187
188 &reg_ldo3 {
189         regulator-min-microvolt = <3300000>;
190         regulator-max-microvolt = <3300000>;
191         regulator-name = "vcc-wifi";
192 };
193
194 &reg_usb0_vbus {
195         gpio = <&pio 1 4 GPIO_ACTIVE_HIGH>; /* PB4 */
196         status = "okay";
197 };
198
199 &usbphy {
200         usb0_vbus-supply = <&reg_usb0_vbus>;
201         usb1_vbus-supply = <&reg_ldo3>;
202         status = "okay";
203 };