]>
Commit | Line | Data |
---|---|---|
0e233720 MR |
1 | /* |
2 | * Copyright (C) 2017 Touchless Biometric Systems AG | |
3 | * Tomas Novotny <tomas@novotny.cz> | |
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 | * Or, alternatively, | |
21 | * | |
22 | * b) Permission is hereby granted, free of charge, to any person | |
23 | * obtaining a copy of this software and associated documentation | |
24 | * files (the "Software"), to deal in the Software without | |
25 | * restriction, including without limitation the rights to use, | |
26 | * copy, modify, merge, publish, distribute, sublicense, and/or | |
27 | * sell copies of the Software, and to permit persons to whom the | |
28 | * Software is furnished to do so, subject to the following | |
29 | * conditions: | |
30 | * | |
31 | * The above copyright notice and this permission notice shall be | |
32 | * included in all copies or substantial portions of the Software. | |
33 | * | |
34 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | |
35 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES | |
36 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | |
37 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT | |
38 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, | |
39 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | |
40 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR | |
41 | * OTHER DEALINGS IN THE SOFTWARE. | |
42 | */ | |
43 | ||
44 | /dts-v1/; | |
45 | #include "sun8i-a83t.dtsi" | |
90c5d7cd MR |
46 | |
47 | #include <dt-bindings/gpio/gpio.h> | |
0e233720 MR |
48 | |
49 | / { | |
50 | model = "TBS A711 Tablet"; | |
51 | compatible = "tbs-biometrics,a711", "allwinner,sun8i-a83t"; | |
52 | ||
53 | aliases { | |
54 | serial0 = &uart0; | |
55 | serial1 = &uart1; | |
56 | }; | |
57 | ||
58 | chosen { | |
59 | stdout-path = "serial0:115200n8"; | |
60 | }; | |
61 | ||
62 | reg_vbat: reg-vbat { | |
63 | compatible = "regulator-fixed"; | |
64 | regulator-name = "vbat"; | |
65 | regulator-min-microvolt = <3700000>; | |
66 | regulator-max-microvolt = <3700000>; | |
67 | }; | |
68 | ||
69 | reg_vmain: reg-vmain { | |
70 | compatible = "regulator-fixed"; | |
71 | regulator-name = "vmain"; | |
72 | regulator-min-microvolt = <5000000>; | |
73 | regulator-max-microvolt = <5000000>; | |
74 | gpio = <&r_pio 0 9 GPIO_ACTIVE_HIGH>; | |
75 | enable-active-high; | |
76 | vin-supply = <®_vbat>; | |
77 | }; | |
78 | ||
79 | wifi_pwrseq: wifi_pwrseq { | |
80 | compatible = "mmc-pwrseq-simple"; | |
81 | reset-gpios = <&r_pio 0 2 GPIO_ACTIVE_LOW>; /* PL2 WL-PMU-EN */ | |
82 | ||
83 | /* | |
84 | * This is actually Bluetooth's clock, but we have to | |
85 | * hook it up somewheere | |
86 | */ | |
87 | clocks = <&ac100_rtc 1>; | |
88 | clock-names = "ext_clock"; | |
89 | }; | |
90 | }; | |
91 | ||
92 | /* | |
93 | * An USB-2 hub is connected here, which also means we don't need to | |
94 | * enable the OHCI controller. | |
95 | */ | |
96 | &ehci0 { | |
97 | status = "okay"; | |
98 | }; | |
99 | ||
100 | /* | |
101 | * There's a modem connected here that needs to be initialised before | |
102 | * being able to be enumerated. | |
103 | */ | |
104 | &ehci1 { | |
105 | status = "okay"; | |
106 | }; | |
107 | ||
108 | &mmc0 { | |
90c5d7cd | 109 | vmmc-supply = <®_dcdc1>; |
0e233720 MR |
110 | pinctrl-names = "default"; |
111 | pinctrl-0 = <&mmc0_pins>; | |
112 | cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; | |
113 | status = "okay"; | |
114 | }; | |
115 | ||
116 | &mmc1 { | |
117 | mmc-pwrseq = <&wifi_pwrseq>; | |
118 | bus-width = <4>; | |
90c5d7cd MR |
119 | vmmc-supply = <®_dldo1>; |
120 | vqmmc-supply = <®_dldo1>; | |
0e233720 MR |
121 | non-removable; |
122 | wakeup-source; | |
123 | status = "okay"; | |
124 | ||
125 | brcmf: wifi@1 { | |
126 | reg = <1>; | |
127 | compatible = "brcm,bcm4329-fmac"; | |
128 | interrupt-parent = <&r_pio>; | |
129 | interrupts = <0 3 IRQ_TYPE_LEVEL_LOW>; /* PL3 WL_WAKE_UP */ | |
130 | interrupt-names = "host-wake"; | |
131 | }; | |
132 | }; | |
133 | ||
134 | &mmc2 { | |
135 | pinctrl-0 = <&mmc2_8bit_emmc_pins>; | |
136 | pinctrl-names = "default"; | |
90c5d7cd MR |
137 | vmmc-supply = <®_dcdc1>; |
138 | vqmmc-supply = <®_dcdc1>; | |
0e233720 MR |
139 | bus-width = <8>; |
140 | non-removable; | |
141 | cap-mmc-hw-reset; | |
142 | status = "okay"; | |
143 | }; | |
144 | ||
145 | &r_rsb { | |
146 | status = "okay"; | |
147 | ||
90c5d7cd | 148 | axp81x: pmic@3a3 { |
eac6a363 | 149 | compatible = "x-powers,axp813"; |
0e233720 MR |
150 | reg = <0x3a3>; |
151 | interrupt-parent = <&r_intc>; | |
152 | interrupts = <0 IRQ_TYPE_LEVEL_LOW>; | |
90c5d7cd MR |
153 | swin-supply = <®_dcdc1>; |
154 | x-powers,drive-vbus-en; | |
0e233720 MR |
155 | }; |
156 | ||
157 | ac100: codec@e89 { | |
158 | compatible = "x-powers,ac100"; | |
159 | reg = <0xe89>; | |
160 | ||
161 | ac100_codec: codec { | |
162 | compatible = "x-powers,ac100-codec"; | |
163 | interrupt-parent = <&r_pio>; | |
164 | interrupts = <0 12 IRQ_TYPE_LEVEL_LOW>; /* PL12 */ | |
165 | #clock-cells = <0>; | |
166 | clock-output-names = "4M_adda"; | |
167 | }; | |
168 | ||
169 | ac100_rtc: rtc { | |
170 | compatible = "x-powers,ac100-rtc"; | |
171 | interrupt-parent = <&r_intc>; | |
172 | interrupts = <0 IRQ_TYPE_LEVEL_LOW>; | |
173 | clocks = <&ac100_codec>; | |
174 | #clock-cells = <1>; | |
175 | clock-output-names = "cko1_rtc", | |
176 | "cko2_rtc", | |
177 | "cko3_rtc"; | |
178 | }; | |
179 | }; | |
180 | ||
181 | }; | |
182 | ||
90c5d7cd MR |
183 | #include "axp81x.dtsi" |
184 | ||
185 | ®_aldo1 { | |
186 | regulator-min-microvolt = <1800000>; | |
187 | regulator-max-microvolt = <1800000>; | |
188 | regulator-name = "vcc-1.8"; | |
189 | }; | |
190 | ||
191 | ®_aldo2 { | |
192 | regulator-min-microvolt = <1800000>; | |
193 | regulator-max-microvolt = <1800000>; | |
194 | regulator-always-on; | |
195 | regulator-name = "vdd-drampll"; | |
196 | }; | |
197 | ||
198 | ®_aldo3 { | |
199 | regulator-min-microvolt = <3000000>; | |
200 | regulator-max-microvolt = <3000000>; | |
201 | regulator-always-on; | |
202 | regulator-name = "avcc"; | |
203 | }; | |
204 | ||
205 | ®_dcdc1 { | |
206 | regulator-min-microvolt = <3100000>; | |
207 | regulator-max-microvolt = <3100000>; | |
208 | regulator-always-on; | |
209 | regulator-name = "vcc-io"; | |
210 | }; | |
211 | ||
212 | ®_dcdc2 { | |
213 | regulator-min-microvolt = <700000>; | |
214 | regulator-max-microvolt = <1100000>; | |
215 | regulator-always-on; | |
216 | regulator-name = "vdd-cpu-A"; | |
217 | }; | |
218 | ||
219 | ®_dcdc3 { | |
220 | regulator-min-microvolt = <700000>; | |
221 | regulator-max-microvolt = <1100000>; | |
222 | regulator-always-on; | |
223 | regulator-name = "vdd-cpu-B"; | |
224 | }; | |
225 | ||
226 | ®_dcdc4 { | |
227 | regulator-min-microvolt = <700000>; | |
228 | regulator-max-microvolt = <1100000>; | |
229 | regulator-name = "vdd-gpu"; | |
230 | }; | |
231 | ||
232 | ®_dcdc5 { | |
233 | regulator-min-microvolt = <1200000>; | |
234 | regulator-max-microvolt = <1500000>; | |
235 | regulator-always-on; | |
236 | regulator-name = "vcc-dram"; | |
237 | }; | |
238 | ||
239 | ®_dcdc6 { | |
240 | regulator-min-microvolt = <900000>; | |
241 | regulator-max-microvolt = <900000>; | |
242 | regulator-always-on; | |
243 | regulator-name = "vdd-sys"; | |
244 | }; | |
245 | ||
246 | ®_dldo1 { | |
247 | regulator-min-microvolt = <3100000>; | |
248 | regulator-max-microvolt = <3100000>; | |
249 | regulator-name = "vcc-wifi-io"; | |
250 | }; | |
251 | ||
252 | ®_dldo2 { | |
253 | regulator-min-microvolt = <2800000>; | |
254 | regulator-max-microvolt = <4200000>; | |
255 | regulator-name = "vcc-mipi"; | |
256 | }; | |
257 | ||
258 | ®_dldo3 { | |
259 | regulator-min-microvolt = <2800000>; | |
260 | regulator-max-microvolt = <2800000>; | |
261 | regulator-name = "vdd-csi"; | |
262 | }; | |
263 | ||
264 | ®_dldo4 { | |
265 | regulator-min-microvolt = <2800000>; | |
266 | regulator-max-microvolt = <2800000>; | |
267 | regulator-name = "avdd-csi"; | |
268 | }; | |
269 | ||
270 | ®_drivevbus { | |
271 | regulator-name = "usb0-vbus"; | |
272 | status = "okay"; | |
273 | }; | |
274 | ||
275 | ®_eldo1 { | |
276 | regulator-min-microvolt = <1200000>; | |
277 | regulator-max-microvolt = <1800000>; | |
278 | regulator-name = "dvdd-csi-r"; | |
279 | }; | |
280 | ||
281 | ®_eldo2 { | |
282 | regulator-min-microvolt = <1800000>; | |
283 | regulator-max-microvolt = <1800000>; | |
284 | regulator-name = "vcc-dsi"; | |
285 | }; | |
286 | ||
287 | ®_eldo3 { | |
288 | regulator-min-microvolt = <1200000>; | |
289 | regulator-max-microvolt = <1800000>; | |
290 | regulator-name = "dvdd-csi-f"; | |
291 | }; | |
292 | ||
293 | ®_fldo1 { | |
294 | regulator-min-microvolt = <1200000>; | |
295 | regulator-max-microvolt = <1200000>; | |
296 | regulator-name = "vcc-hsic"; | |
297 | }; | |
298 | ||
299 | ®_fldo2 { | |
300 | regulator-min-microvolt = <700000>; | |
301 | regulator-max-microvolt = <1100000>; | |
302 | regulator-always-on; | |
303 | regulator-name = "vdd-cpus"; | |
304 | }; | |
305 | ||
306 | ®_ldo_io0 { | |
307 | regulator-min-microvolt = <3100000>; | |
308 | regulator-max-microvolt = <3100000>; | |
309 | regulator-name = "vcc-ctp"; | |
310 | status = "okay"; | |
311 | }; | |
312 | ||
313 | ®_ldo_io1 { | |
314 | regulator-min-microvolt = <3100000>; | |
315 | regulator-max-microvolt = <3100000>; | |
316 | regulator-name = "vcc-vb"; | |
317 | status = "okay"; | |
318 | }; | |
319 | ||
320 | ®_sw { | |
321 | regulator-min-microvolt = <3100000>; | |
322 | regulator-max-microvolt = <3100000>; | |
323 | regulator-name = "vcc-lcd"; | |
324 | }; | |
325 | ||
0e233720 MR |
326 | &uart0 { |
327 | pinctrl-names = "default"; | |
328 | pinctrl-0 = <&uart0_pb_pins>; | |
329 | status = "okay"; | |
330 | }; | |
331 | ||
332 | /* There's the BT part of the AP6210 connected to that UART */ | |
333 | &uart1 { | |
334 | pinctrl-names = "default"; | |
335 | pinctrl-0 = <&uart1_pins>, <&uart1_rts_cts_pins>; | |
336 | status = "okay"; | |
337 | }; | |
338 | ||
f2f221c7 MR |
339 | &usb_otg { |
340 | dr_mode = "otg"; | |
341 | status = "okay"; | |
342 | }; | |
343 | ||
0e233720 | 344 | &usbphy { |
f2f221c7 MR |
345 | usb0_id_det-gpios = <&pio 7 11 GPIO_ACTIVE_HIGH>; /* PH11 */ |
346 | usb0_vbus-supply = <®_drivevbus>; | |
90c5d7cd MR |
347 | usb1_vbus_supply = <®_vmain>; |
348 | usb2_vbus_supply = <®_vmain>; | |
0e233720 MR |
349 | status = "okay"; |
350 | }; |