2 * sun9i-a80-cx-a99.dts - Device Tree file for the Sunchip CX-A99 board.
4 * Copyright (C) 2017 Rask Ingemann Lambertsen <rask@formelder.dk>
6 * This file is dual-licensed: you can use it either under the terms
7 * of the GPL or the X11 license, at your option. Note that this dual
8 * licensing only applies to this file, and not this project as a
11 * a) This file is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU General Public License as
13 * published by the Free Software Foundation; either version 2 of the
14 * License, or (at your option) any later version.
16 * This file is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
23 * b) Permission is hereby granted, free of charge, to any person
24 * obtaining a copy of this software and associated documentation
25 * files (the "Software"), to deal in the Software without
26 * restriction, including without limitation the rights to use,
27 * copy, modify, merge, publish, distribute, sublicense, and/or
28 * sell copies of the Software, and to permit persons to whom the
29 * Software is furnished to do so, subject to the following
32 * The above copyright notice and this permission notice shall be
33 * included in all copies or substantial portions of the Software.
35 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
36 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
37 * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
38 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
39 * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
40 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
41 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
42 * OTHER DEALINGS IN THE SOFTWARE.
46 * The Sunchip CX-A99 board is found in several similar Android media
49 * Instabox Fantasy A8 (no external antenna)
50 * Jesurun CS-Q8 (ships with larger remote control)
52 * Rikomagic (RKM) MK80/MK80LE
53 * Tronsmart Draco AW80 Meta/Telos
55 * See the Sunchip CX-A99 page on the Linux-sunxi wiki for more information.
59 #include "sun9i-a80.dtsi"
61 #include <dt-bindings/gpio/gpio.h>
64 model = "Sunchip CX-A99";
65 compatible = "sunchip,cx-a99", "allwinner,sun9i-a80";
72 stdout-path = "serial0:115200n8";
76 compatible = "gpio-leds";
79 gpios = <&pio 6 10 GPIO_ACTIVE_HIGH>; /* PG10 */
80 label = "cx-a99:blue:status";
84 gpios = <&pio 6 11 GPIO_ACTIVE_HIGH>; /* PG11 */
85 label = "cx-a99:red:status";
89 powerseq_wifi: powerseq-wifi {
90 compatible = "mmc-pwrseq-simple";
91 clocks = <&ac100_rtc 1>;
92 clock-names = "ext_clock";
93 reset-gpios = <&r_pio 1 0 GPIO_ACTIVE_LOW>; /* PM0 */
94 post-power-on-delay-ms = <1>; /* Minimum 2 cycles. */
97 /* USB 2.0 connector closest to the 12 V power connector. */
98 reg_usb1_vbus: regulator-usb1-vbus {
99 compatible = "regulator-fixed";
100 regulator-name = "usb1-vbus";
101 regulator-min-microvolt = <5000000>;
102 regulator-max-microvolt = <5000000>;
103 gpio = <&r_pio 0 7 /* no flag support */ 0>; /* PL7 */
107 /* USB 2.0 connector next to the SD card slot. */
108 reg_usb3_vbus: regulator-usb3-vbus {
109 compatible = "regulator-fixed";
110 regulator-name = "usb3-vbus";
111 regulator-min-microvolt = <5000000>;
112 regulator-max-microvolt = <5000000>;
113 gpio = <&r_pio 0 8 /* no flag support */ 0>; /* PL8 */
118 * OZ80120 voltage regulator for the four Cortex-A15 CPU cores.
119 * Although the regulator can output 750 - 1200 mV, the permissible
120 * range for the CPU cores is only 800 - 1100 mV.
122 reg_vdd_cpub: regulator-vdd-cpub {
123 compatible = "regulator-gpio";
126 regulator-min-microvolt = < 800000>;
127 regulator-max-microvolt = <1100000>;
128 regulator-name = "vdd-cpub";
130 /* Note: GPIO flags are not supported here . */
131 enable-gpio = <&r_pio 0 2 /* flags n/a */ 0>; /* PL2 */
133 gpios = <&r_pio 0 3 /* no flag support */ 0>, /* PL3 */
134 <&r_pio 0 4 /* no flag support */ 0>, /* PL4 */
135 <&r_pio 0 5 /* no flag support */ 0>; /* PL5 */
137 gpios-states = <1 0 0>;
138 states = < 750000 0x7
158 * SD card slot. Although the GPIO pin for card detection is listed as capable
159 * of generating interrupts in the "A80 User Manual", this doesn't work for
160 * some unknown reason, so poll the GPIO for card detection. This is also what
161 * the vendor sys_config.fex file specifies.
165 cd-gpios = <&pio 7 17 GPIO_ACTIVE_LOW>; /* PH17 */
166 broken-cd; /* Poll. */
167 pinctrl-names = "default";
168 pinctrl-0 = <&mmc0_pins>;
169 vmmc-supply = <®_dcdce>;
173 /* Ampak AP6335 IEEE 802.11 a/b/g/n/ac Wifi. */
177 pinctrl-names = "default";
178 pinctrl-0 = <&mmc1_pins>;
179 vmmc-supply = <®_cldo3>; /* See cldo2,cldo3 note. */
180 vqmmc-supply = <®_aldo2>;
181 mmc-pwrseq = <&powerseq_wifi>;
185 /* On-board eMMC card. */
189 pinctrl-names = "default";
190 pinctrl-0 = <&mmc2_8bit_pins>;
191 vmmc-supply = <®_dcdce>;
196 clocks = <&ac100_rtc 0>;
207 compatible = "x-powers,ac100";
211 compatible = "x-powers,ac100-codec";
212 interrupt-parent = <&r_pio>;
213 interrupts = <0 9 IRQ_TYPE_LEVEL_LOW>; /* PL9 */
215 clock-output-names = "4M_adda";
219 compatible = "x-powers,ac100-rtc";
220 interrupt-parent = <&nmi_intc>;
221 interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
222 clocks = <&ac100_codec>;
224 clock-output-names = "cko1_rtc",
231 compatible = "x-powers,axp808", "x-powers,axp806";
232 x-powers,master-mode;
234 interrupt-parent = <&nmi_intc>;
235 interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
236 interrupt-controller;
237 #interrupt-cells = <1>;
239 swin-supply = <®_dcdce>;
244 regulator-min-microvolt = <3000000>;
245 regulator-max-microvolt = <3000000>;
246 regulator-name = "vcc-3v0";
249 /* Supplies pin groups G and M. */
252 regulator-min-microvolt = <1800000>;
253 regulator-max-microvolt = <3600000>;
254 regulator-name = "vddio-wifi-codec";
259 regulator-min-microvolt = <2500000>;
260 regulator-max-microvolt = <2500000>;
261 regulator-name = "vddio-gmac";
265 regulator-always-on; /* Hang if disabled */
266 regulator-min-microvolt = <1700000>;
267 regulator-max-microvolt = <1900000>;
268 regulator-name = "vdd18-dll-vcc18-pll";
272 regulator-always-on; /* Hang if disabled */
273 regulator-min-microvolt = < 800000>;
274 regulator-max-microvolt = <1100000>;
275 regulator-name = "vdd-cpus";
279 regulator-min-microvolt = <1100000>;
280 regulator-max-microvolt = <1300000>;
281 regulator-name = "vcc12-hsic";
286 regulator-min-microvolt = < 800000>;
287 regulator-max-microvolt = <1100000>;
288 regulator-name = "vdd09-hdmi";
291 /* Supplies PLx pins which control some regulators. */
294 regulator-min-microvolt = <3300000>;
295 regulator-max-microvolt = <3300000>;
296 regulator-name = "vcc-pl-led";
300 * cldo2 and cldo3 are connected in parallel.
301 * There is currently no way to express that.
302 * For now, use regulator-always-on on cldo2 and lock
303 * the voltage on both to 3.3 V.
307 regulator-min-microvolt = <3300000>;
308 regulator-max-microvolt = <3300000>;
309 regulator-name = "vbat2-wifi+bt";
313 regulator-min-microvolt = <3300000>;
314 regulator-max-microvolt = <3300000>;
315 regulator-name = "vbat1-wifi+bt";
320 regulator-min-microvolt = < 800000>;
321 regulator-max-microvolt = <1100000>;
322 regulator-name = "vdd-cpua";
327 regulator-min-microvolt = <1450000>;
328 regulator-max-microvolt = <1550000>;
329 regulator-name = "vcc-dram";
333 regulator-min-microvolt = < 800000>;
334 regulator-max-microvolt = <1100000>;
335 regulator-name = "vdd-gpu";
339 regulator-always-on; /* Hang if disabled. */
340 regulator-min-microvolt = < 800000>;
341 regulator-max-microvolt = <1100000>;
342 regulator-name = "vdd-sys";
345 /* Supplies pin groups B-F and H. */
348 regulator-min-microvolt = <3300000>;
349 regulator-max-microvolt = <3300000>;
350 regulator-name = "vcc-io-mmc-spdif";
354 regulator-min-microvolt = <3300000>;
355 regulator-max-microvolt = <3300000>;
356 regulator-name = "vcc-gmac-codec";
363 * 5-pin connector opposite of the SD card slot:
364 * 1 = GND (pointed to by small triangle), 2 = GND, 3 = 3.3 V, 4 = RX, 5 = TX.
367 pinctrl-names = "default";
368 pinctrl-0 = <&uart0_ph_pins>;
373 phy-supply = <®_usb1_vbus>;
378 phy-supply = <®_usb3_vbus>;