1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT)
3 * Copyright (c) 2016 Endless Computers, Inc.
4 * Author: Carlo Caione <carlo@endlessm.com>
7 /* Common DTSI for same Amlogic Q200/Q201 and P230/P231 boards using either
8 * the pin-compatible S912 (GXM) or S905D (GXL) SoCs.
11 #include <dt-bindings/sound/meson-aiu.h>
19 dio2133: analog-amplifier {
20 compatible = "simple-audio-amplifier";
21 sound-name-prefix = "AU2";
22 VCC-supply = <&hdmi_5v>;
23 enable-gpios = <&gpio GPIOH_5 GPIO_ACTIVE_HIGH>;
26 spdif_dit: audio-codec-0 {
27 #sound-dai-cells = <0>;
28 compatible = "linux,spdif-dit";
29 sound-name-prefix = "DIT";
33 stdout-path = "serial0:115200n8";
37 device_type = "memory";
38 reg = <0x0 0x0 0x0 0x80000000>;
41 hdmi_5v: regulator-hdmi-5v {
42 compatible = "regulator-fixed";
44 regulator-name = "HDMI_5V";
45 regulator-min-microvolt = <5000000>;
46 regulator-max-microvolt = <5000000>;
48 gpio = <&gpio GPIOH_3 GPIO_ACTIVE_HIGH>;
53 vddio_ao18: regulator-vddio-ao18 {
54 compatible = "regulator-fixed";
55 regulator-name = "VDDIO_AO18";
56 regulator-min-microvolt = <1800000>;
57 regulator-max-microvolt = <1800000>;
60 vddio_boot: regulator-vddio-boot {
61 compatible = "regulator-fixed";
62 regulator-name = "VDDIO_BOOT";
63 regulator-min-microvolt = <1800000>;
64 regulator-max-microvolt = <1800000>;
67 vddao_3v3: regulator-vddao-3v3 {
68 compatible = "regulator-fixed";
69 regulator-name = "VDDAO_3V3";
70 regulator-min-microvolt = <3300000>;
71 regulator-max-microvolt = <3300000>;
74 vcc_3v3: regulator-vcc-3v3 {
75 compatible = "regulator-fixed";
76 regulator-name = "VCC_3V3";
77 regulator-min-microvolt = <3300000>;
78 regulator-max-microvolt = <3300000>;
81 emmc_pwrseq: emmc-pwrseq {
82 compatible = "mmc-pwrseq-emmc";
83 reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>;
87 compatible = "pwm-clock";
89 clock-frequency = <32768>;
90 pwms = <&pwm_ef 0 30518 0>; /* PWM_E at 32.768KHz */
93 sdio_pwrseq: sdio-pwrseq {
94 compatible = "mmc-pwrseq-simple";
95 reset-gpios = <&gpio GPIOX_6 GPIO_ACTIVE_LOW>;
97 clock-names = "ext_clock";
101 compatible = "composite-video-connector";
104 cvbs_connector_in: endpoint {
105 remote-endpoint = <&cvbs_vdac_out>;
111 compatible = "hdmi-connector";
115 hdmi_connector_in: endpoint {
116 remote-endpoint = <&hdmi_tx_tmds_out>;
122 compatible = "amlogic,gx-sound-card";
124 audio-aux-devs = <&dio2133>;
125 audio-widgets = "Line", "Lineout";
126 audio-routing = "AU2 INL", "ACODEC LOLP",
127 "AU2 INR", "ACODEC LORP",
128 "AU2 INL", "ACODEC LOLN",
129 "AU2 INR", "ACODEC LORN",
130 "Lineout", "AU2 OUTL",
131 "Lineout", "AU2 OUTR";
132 assigned-clocks = <&clkc CLKID_MPLL0>,
135 assigned-clock-parents = <0>, <0>, <0>;
136 assigned-clock-rates = <294912000>,
140 sound-dai = <&aiu AIU_CPU CPU_I2S_FIFO>;
144 sound-dai = <&aiu AIU_CPU CPU_SPDIF_FIFO>;
148 sound-dai = <&aiu AIU_CPU CPU_I2S_ENCODER>;
153 sound-dai = <&aiu AIU_HDMI CTRL_I2S>;
157 sound-dai = <&aiu AIU_ACODEC CTRL_I2S>;
162 sound-dai = <&aiu AIU_CPU CPU_SPDIF_ENCODER>;
165 sound-dai = <&spdif_dit>;
170 sound-dai = <&aiu AIU_HDMI CTRL_OUT>;
173 sound-dai = <&hdmi_tx>;
178 sound-dai = <&aiu AIU_ACODEC CTRL_OUT>;
181 sound-dai = <&acodec>;
188 AVDD-supply = <&vddio_ao18>;
194 pinctrl-0 = <&spdif_out_h_pins>;
195 pinctrl-names = "default";
201 pinctrl-0 = <&ao_cec_pins>;
202 pinctrl-names = "default";
203 hdmi-phandle = <&hdmi_tx>;
207 cvbs_vdac_out: endpoint {
208 remote-endpoint = <&cvbs_connector_in>;
218 pinctrl-0 = <&hdmi_hpd_pins>, <&hdmi_i2c_pins>;
219 pinctrl-names = "default";
220 hdmi-supply = <&hdmi_5v>;
224 hdmi_tx_tmds_out: endpoint {
225 remote-endpoint = <&hdmi_connector_in>;
231 pinctrl-0 = <&remote_input_ao_pins>;
232 pinctrl-names = "default";
237 pinctrl-0 = <&pwm_e_pins>;
238 pinctrl-names = "default";
239 clocks = <&clkc CLKID_FCLK_DIV4>;
240 clock-names = "clkin0";
245 vref-supply = <&vddio_ao18>;
248 /* Wireless SDIO Module */
251 pinctrl-0 = <&sdio_pins>;
252 pinctrl-1 = <&sdio_clk_gate_pins>;
253 pinctrl-names = "default", "clk-gate";
254 #address-cells = <1>;
259 max-frequency = <50000000>;
264 /* WiFi firmware requires power to be kept while in suspend */
265 keep-power-in-suspend;
267 mmc-pwrseq = <&sdio_pwrseq>;
269 vmmc-supply = <&vddao_3v3>;
270 vqmmc-supply = <&vddio_boot>;
276 pinctrl-0 = <&sdcard_pins>;
277 pinctrl-1 = <&sdcard_clk_gate_pins>;
278 pinctrl-names = "default", "clk-gate";
282 max-frequency = <50000000>;
285 cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_LOW>;
287 vmmc-supply = <&vddao_3v3>;
288 vqmmc-supply = <&vddio_boot>;
294 pinctrl-0 = <&emmc_pins>, <&emmc_ds_pins>;
295 pinctrl-1 = <&emmc_clk_gate_pins>;
296 pinctrl-names = "default", "clk-gate";
300 max-frequency = <200000000>;
306 mmc-pwrseq = <&emmc_pwrseq>;
307 vmmc-supply = <&vcc_3v3>;
308 vqmmc-supply = <&vddio_boot>;
311 /* This UART is brought out to the DB9 connector */
314 pinctrl-0 = <&uart_ao_a_pins>;
315 pinctrl-names = "default";