]>
Commit | Line | Data |
---|---|---|
c690d80b HG |
1 | /* |
2 | * Copyright 2014 Hans de Goede <hdegoede@redhat.com> | |
3 | * | |
438989fa MR |
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. | |
c690d80b | 8 | * |
438989fa MR |
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. | |
c690d80b HG |
46 | */ |
47 | ||
48 | /dts-v1/; | |
49 | /include/ "sun7i-a20.dtsi" | |
50 | /include/ "sunxi-common-regulators.dtsi" | |
51 | ||
52 | / { | |
53 | model = "I12 / Q5 / QT840A A20 tvbox"; | |
54 | compatible = "allwinner,i12-tvbox", "allwinner,sun7i-a20"; | |
55 | ||
56 | soc@01c00000 { | |
57 | mmc0: mmc@01c0f000 { | |
58 | pinctrl-names = "default"; | |
59 | pinctrl-0 = <&mmc0_pins_a>, <&mmc0_cd_pin_reference_design>; | |
60 | vmmc-supply = <®_vcc3v3>; | |
61 | bus-width = <4>; | |
62 | cd-gpios = <&pio 7 1 0>; /* PH1 */ | |
63 | cd-inverted; | |
64 | status = "okay"; | |
65 | }; | |
66 | ||
67 | mmc3: mmc@01c12000 { | |
68 | pinctrl-names = "default"; | |
69 | pinctrl-0 = <&mmc3_pins_a>; | |
70 | vmmc-supply = <®_vmmc3>; | |
71 | bus-width = <4>; | |
72 | non-removable; | |
73 | status = "okay"; | |
74 | }; | |
75 | ||
76 | usbphy: phy@01c13400 { | |
77 | usb1_vbus-supply = <®_usb1_vbus>; | |
78 | usb2_vbus-supply = <®_usb2_vbus>; | |
79 | status = "okay"; | |
80 | }; | |
81 | ||
82 | ehci0: usb@01c14000 { | |
83 | status = "okay"; | |
84 | }; | |
85 | ||
86 | ohci0: usb@01c14400 { | |
87 | status = "okay"; | |
88 | }; | |
89 | ||
90 | ehci1: usb@01c1c000 { | |
91 | status = "okay"; | |
92 | }; | |
93 | ||
94 | ohci1: usb@01c1c400 { | |
95 | status = "okay"; | |
96 | }; | |
97 | ||
98 | pinctrl@01c20800 { | |
99 | mmc3_pins_a: mmc3@0 { | |
100 | /* AP6210 / AP6330 requires pull-up */ | |
101 | allwinner,pull = <1>; | |
102 | }; | |
103 | ||
104 | vmmc3_pin_i12_tvbox: vmmc3_pin@0 { | |
105 | allwinner,pins = "PH2"; | |
106 | allwinner,function = "gpio_out"; | |
107 | allwinner,drive = <0>; | |
108 | allwinner,pull = <0>; | |
109 | }; | |
110 | ||
111 | vmmc3_io_pin_i12_tvbox: vmmc3_io_pin@0 { | |
112 | allwinner,pins = "PH12"; | |
113 | allwinner,function = "gpio_out"; | |
114 | allwinner,drive = <0>; | |
115 | allwinner,pull = <0>; | |
116 | }; | |
117 | ||
118 | gmac_power_pin_i12_tvbox: gmac_power_pin@0 { | |
119 | allwinner,pins = "PH21"; | |
120 | allwinner,function = "gpio_out"; | |
121 | allwinner,drive = <0>; | |
122 | allwinner,pull = <0>; | |
123 | }; | |
124 | ||
125 | led_pins_i12_tvbox: led_pins@0 { | |
126 | allwinner,pins = "PH9", "PH20"; | |
127 | allwinner,function = "gpio_out"; | |
128 | allwinner,drive = <0>; | |
129 | allwinner,pull = <0>; | |
130 | }; | |
131 | }; | |
132 | ||
abe36869 HG |
133 | ir0: ir@01c21800 { |
134 | pinctrl-names = "default"; | |
135 | pinctrl-0 = <&ir0_pins_a>; | |
136 | status = "okay"; | |
137 | }; | |
138 | ||
c690d80b HG |
139 | uart0: serial@01c28000 { |
140 | pinctrl-names = "default"; | |
141 | pinctrl-0 = <&uart0_pins_a>; | |
142 | status = "okay"; | |
143 | }; | |
144 | ||
ec0c933d CC |
145 | i2c0: i2c@01c2ac00 { |
146 | pinctrl-names = "default"; | |
147 | pinctrl-0 = <&i2c0_pins_a>; | |
148 | status = "okay"; | |
149 | ||
150 | axp209: pmic@34 { | |
151 | compatible = "x-powers,axp209"; | |
152 | reg = <0x34>; | |
153 | interrupt-parent = <&nmi_intc>; | |
154 | interrupts = <0 8>; | |
155 | ||
156 | interrupt-controller; | |
157 | #interrupt-cells = <1>; | |
158 | }; | |
159 | }; | |
160 | ||
c690d80b HG |
161 | gmac: ethernet@01c50000 { |
162 | pinctrl-names = "default"; | |
163 | pinctrl-0 = <&gmac_pins_mii_a>; | |
164 | phy = <&phy1>; | |
165 | phy-mode = "mii"; | |
166 | phy-supply = <®_gmac_3v3>; | |
167 | status = "okay"; | |
168 | ||
169 | phy1: ethernet-phy@1 { | |
170 | reg = <1>; | |
171 | }; | |
172 | }; | |
173 | }; | |
174 | ||
175 | leds { | |
176 | compatible = "gpio-leds"; | |
177 | pinctrl-names = "default"; | |
178 | pinctrl-0 = <&led_pins_i12_tvbox>; | |
179 | ||
180 | red { | |
181 | label = "i12_tvbox:red:usr"; | |
182 | gpios = <&pio 7 9 1>; | |
183 | }; | |
184 | ||
185 | blue { | |
186 | label = "i12_tvbox:blue:usr"; | |
187 | gpios = <&pio 7 20 0>; | |
188 | }; | |
189 | }; | |
190 | ||
191 | reg_usb1_vbus: usb1-vbus { | |
192 | status = "okay"; | |
193 | }; | |
194 | ||
195 | reg_usb2_vbus: usb2-vbus { | |
196 | status = "okay"; | |
197 | }; | |
198 | ||
199 | reg_vmmc3: vmmc3 { | |
200 | compatible = "regulator-fixed"; | |
201 | pinctrl-names = "default"; | |
202 | pinctrl-0 = <&vmmc3_pin_i12_tvbox>; | |
203 | regulator-name = "vmmc3"; | |
204 | regulator-min-microvolt = <3300000>; | |
205 | regulator-max-microvolt = <3300000>; | |
206 | enable-active-high; | |
207 | gpio = <&pio 7 2 0>; | |
208 | }; | |
209 | ||
210 | reg_vmmc3_io: vmmc3-io { | |
211 | compatible = "regulator-fixed"; | |
212 | pinctrl-names = "default"; | |
213 | pinctrl-0 = <&vmmc3_io_pin_i12_tvbox>; | |
214 | regulator-name = "vmmc3-io"; | |
215 | regulator-min-microvolt = <3300000>; | |
216 | regulator-max-microvolt = <3300000>; | |
217 | /* This controls VCC-PI, must be always on! */ | |
218 | regulator-always-on; | |
219 | enable-active-high; | |
220 | gpio = <&pio 7 12 0>; | |
221 | }; | |
222 | ||
223 | reg_gmac_3v3: gmac-3v3 { | |
224 | compatible = "regulator-fixed"; | |
225 | pinctrl-names = "default"; | |
226 | pinctrl-0 = <&gmac_power_pin_i12_tvbox>; | |
227 | regulator-name = "gmac-3v3"; | |
228 | regulator-min-microvolt = <3300000>; | |
229 | regulator-max-microvolt = <3300000>; | |
230 | startup-delay-us = <50000>; | |
231 | enable-active-high; | |
232 | gpio = <&pio 7 21 0>; | |
233 | }; | |
234 | }; |