1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
2 // Copyright (C) 2019 Icenowy Zheng <icenowy@aosc.xyz>
3 // Copyright (C) 2020 Martijn Braam <martijn@brixit.nl>
4 // Copyright (C) 2020 Ondrej Jirman <megous@megous.com>
6 #include "sun50i-a64.dtsi"
7 #include "sun50i-a64-cpu-opp.dtsi"
9 #include <dt-bindings/gpio/gpio.h>
10 #include <dt-bindings/input/input.h>
11 #include <dt-bindings/leds/common.h>
12 #include <dt-bindings/pwm/pwm.h>
20 stdout-path = "serial0:115200n8";
24 compatible = "gpio-leds";
27 function = LED_FUNCTION_INDICATOR;
28 color = <LED_COLOR_ID_BLUE>;
29 gpios = <&pio 3 20 GPIO_ACTIVE_HIGH>; /* PD20 */
33 function = LED_FUNCTION_INDICATOR;
34 color = <LED_COLOR_ID_GREEN>;
35 gpios = <&pio 3 18 GPIO_ACTIVE_HIGH>; /* PD18 */
39 function = LED_FUNCTION_INDICATOR;
40 color = <LED_COLOR_ID_RED>;
41 gpios = <&pio 3 19 GPIO_ACTIVE_HIGH>; /* PD19 */
45 speaker_amp: audio-amplifier {
46 compatible = "simple-audio-amplifier";
47 enable-gpios = <&pio 2 7 GPIO_ACTIVE_HIGH>; /* PC7 */
48 sound-name-prefix = "Speaker Amp";
52 compatible = "gpio-vibrator";
53 enable-gpios = <&pio 3 2 GPIO_ACTIVE_HIGH>; /* PD2 */
54 vcc-supply = <®_dcdc1>;
63 cpvdd-supply = <®_eldo1>;
68 cpu-supply = <®_dcdc2>;
72 cpu-supply = <®_dcdc2>;
76 cpu-supply = <®_dcdc2>;
80 cpu-supply = <®_dcdc2>;
100 compatible = "st,lis3mdl-magn";
102 vdd-supply = <®_dldo1>;
103 vddio-supply = <®_dldo1>;
106 /* Accelerometer/gyroscope */
108 compatible = "invensense,mpu6050";
110 interrupt-parent = <&pio>;
111 interrupts = <7 5 IRQ_TYPE_EDGE_RISING>; /* PH5 */
112 vdd-supply = <®_dldo1>;
113 vddio-supply = <®_dldo1>;
117 /* Connected to pogo pins (external spring based pinheader for user addons) */
123 vref-supply = <®_aldo3>;
128 linux,code = <KEY_VOLUMEUP>;
134 label = "Volume Down";
135 linux,code = <KEY_VOLUMEDOWN>;
142 pinctrl-names = "default";
143 pinctrl-0 = <&mmc0_pins>;
144 vmmc-supply = <®_dcdc1>;
145 vqmmc-supply = <®_dcdc1>;
146 cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */
153 pinctrl-names = "default";
154 pinctrl-0 = <&mmc2_pins>;
155 vmmc-supply = <®_dcdc1>;
156 vqmmc-supply = <®_dcdc1>;
172 vcc-pb-supply = <®_dcdc1>;
173 vcc-pc-supply = <®_dcdc1>;
174 vcc-pd-supply = <®_dcdc1>;
175 vcc-pe-supply = <®_aldo1>;
176 vcc-pf-supply = <®_dcdc1>;
177 vcc-pg-supply = <®_dldo4>;
178 vcc-ph-supply = <®_dcdc1>;
183 * FIXME: We can't add that supply for now since it would
184 * create a circular dependency between pinctrl, the regulator
187 * vcc-pl-supply = <®_aldo2>;
195 compatible = "x-powers,axp803";
197 interrupt-parent = <&r_intc>;
198 interrupts = <0 IRQ_TYPE_LEVEL_LOW>;
202 #include "axp803.dtsi"
208 &battery_power_supply {
213 regulator-min-microvolt = <1800000>;
214 regulator-max-microvolt = <1800000>;
215 regulator-name = "dovdd-csi";
220 regulator-min-microvolt = <1800000>;
221 regulator-max-microvolt = <1800000>;
222 regulator-name = "vcc-pl";
227 regulator-min-microvolt = <2700000>;
228 regulator-max-microvolt = <3300000>;
229 regulator-name = "vcc-pll-avcc";
234 regulator-min-microvolt = <3300000>;
235 regulator-max-microvolt = <3300000>;
236 regulator-name = "vcc-3v3";
241 regulator-min-microvolt = <1000000>;
242 regulator-max-microvolt = <1300000>;
243 regulator-name = "vdd-cpux";
246 /* DCDC3 is polyphased with DCDC2 */
250 regulator-min-microvolt = <1200000>;
251 regulator-max-microvolt = <1200000>;
252 regulator-name = "vcc-dram";
257 regulator-min-microvolt = <1100000>;
258 regulator-max-microvolt = <1100000>;
259 regulator-name = "vdd-sys";
263 regulator-min-microvolt = <3300000>;
264 regulator-max-microvolt = <3300000>;
265 regulator-name = "vcc-dsi-sensor";
269 regulator-min-microvolt = <1800000>;
270 regulator-max-microvolt = <1800000>;
271 regulator-name = "vcc-mipi-io";
275 regulator-min-microvolt = <2800000>;
276 regulator-max-microvolt = <2800000>;
277 regulator-name = "avdd-csi";
281 regulator-min-microvolt = <1800000>;
282 regulator-max-microvolt = <3300000>;
283 regulator-name = "vcc-wifi-io";
288 regulator-min-microvolt = <1800000>;
289 regulator-max-microvolt = <1800000>;
290 regulator-name = "vcc-lpddr";
294 regulator-min-microvolt = <1800000>;
295 regulator-max-microvolt = <1800000>;
296 regulator-name = "dvdd-1v8-csi";
300 regulator-min-microvolt = <1200000>;
301 regulator-max-microvolt = <1200000>;
302 regulator-name = "vcc-1v2-hsic";
307 regulator-min-microvolt = <1100000>;
308 regulator-max-microvolt = <1100000>;
309 regulator-name = "vdd-cpus";
313 regulator-min-microvolt = <3300000>;
314 regulator-max-microvolt = <3300000>;
315 regulator-name = "vcc-lcd-ctp-stk";
320 regulator-min-microvolt = <1800000>;
321 regulator-max-microvolt = <1800000>;
322 regulator-name = "vcc-1v8-typec";
327 regulator-name = "vcc-rtc";
332 simple-audio-card,aux-devs = <&codec_analog>, <&speaker_amp>;
333 simple-audio-card,widgets = "Microphone", "Headset Microphone",
334 "Microphone", "Internal Microphone",
335 "Headphone", "Headphone Jack",
336 "Speaker", "Internal Earpiece",
337 "Speaker", "Internal Speaker";
338 simple-audio-card,routing =
339 "Headphone Jack", "HP",
340 "Internal Earpiece", "EARPIECE",
341 "Internal Speaker", "Speaker Amp OUTL",
342 "Internal Speaker", "Speaker Amp OUTR",
343 "Speaker Amp INL", "LINEOUT",
344 "Speaker Amp INR", "LINEOUT",
345 "Left DAC", "AIF1 Slot 0 Left",
346 "Right DAC", "AIF1 Slot 0 Right",
347 "AIF1 Slot 0 Left ADC", "Left ADC",
348 "AIF1 Slot 0 Right ADC", "Right ADC",
349 "Internal Microphone", "MBIAS",
350 "MIC1", "Internal Microphone",
351 "Headset Microphone", "HBIAS",
352 "MIC2", "Headset Microphone";
356 pinctrl-names = "default";
357 pinctrl-0 = <&uart0_pb_pins>;
361 /* Connected to the modem (hardware flow control can't be used) */
363 pinctrl-names = "default";
364 pinctrl-0 = <&uart3_pins>;
369 dr_mode = "peripheral";