1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2 /* 3 * Copyright (c) 2016 Endless Computers, Inc. 4 * Author: Carlo Caione <carlo@endlessm.com> 5 */ 6 7 /* Common DTSI for same Amlogic Q200/Q201 and P230/P231 boards using either 8 * the pin-compatible S912 (GXM) or S905D (GXL) SoCs. 9 */ 10 11 #include <dt-bindings/sound/meson-aiu.h> 12 13 / { 14 aliases { 15 serial0 = &uart_AO; 16 ethernet0 = ðmac; 17 }; 18 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>; 24 }; 25 26 spdif_dit: audio-codec-0 { 27 #sound-dai-cells = <0>; 28 compatible = "linux,spdif-dit"; 29 sound-name-prefix = "DIT"; 30 }; 31 32 chosen { 33 stdout-path = "serial0:115200n8"; 34 }; 35 36 memory@0 { 37 device_type = "memory"; 38 reg = <0x0 0x0 0x0 0x80000000>; 39 }; 40 41 hdmi_5v: regulator-hdmi-5v { 42 compatible = "regulator-fixed"; 43 44 regulator-name = "HDMI_5V"; 45 regulator-min-microvolt = <5000000>; 46 regulator-max-microvolt = <5000000>; 47 48 gpio = <&gpio GPIOH_3 GPIO_ACTIVE_HIGH>; 49 enable-active-high; 50 regulator-always-on; 51 }; 52 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>; 58 }; 59 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>; 65 }; 66 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>; 72 }; 73 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>; 79 }; 80 81 emmc_pwrseq: emmc-pwrseq { 82 compatible = "mmc-pwrseq-emmc"; 83 reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>; 84 }; 85 86 wifi32k: wifi32k { 87 compatible = "pwm-clock"; 88 #clock-cells = <0>; 89 clock-frequency = <32768>; 90 pwms = <&pwm_ef 0 30518 0>; /* PWM_E at 32.768KHz */ 91 }; 92 93 sdio_pwrseq: sdio-pwrseq { 94 compatible = "mmc-pwrseq-simple"; 95 reset-gpios = <&gpio GPIOX_6 GPIO_ACTIVE_LOW>; 96 clocks = <&wifi32k>; 97 clock-names = "ext_clock"; 98 }; 99 100 cvbs-connector { 101 compatible = "composite-video-connector"; 102 103 port { 104 cvbs_connector_in: endpoint { 105 remote-endpoint = <&cvbs_vdac_out>; 106 }; 107 }; 108 }; 109 110 hdmi-connector { 111 compatible = "hdmi-connector"; 112 type = "a"; 113 114 port { 115 hdmi_connector_in: endpoint { 116 remote-endpoint = <&hdmi_tx_tmds_out>; 117 }; 118 }; 119 }; 120 121 sound { 122 compatible = "amlogic,gx-sound-card"; 123 model = "P230-Q200"; 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 clocks = <&clkc CLKID_MPLL0>, 133 <&clkc CLKID_MPLL1>, 134 <&clkc CLKID_MPLL2>; 135 136 assigned-clocks = <&clkc CLKID_MPLL0>, 137 <&clkc CLKID_MPLL1>, 138 <&clkc CLKID_MPLL2>; 139 assigned-clock-parents = <0>, <0>, <0>; 140 assigned-clock-rates = <294912000>, 141 <270950400>, 142 <393216000>; 143 dai-link-0 { 144 sound-dai = <&aiu AIU_CPU CPU_I2S_FIFO>; 145 }; 146 147 dai-link-1 { 148 sound-dai = <&aiu AIU_CPU CPU_SPDIF_FIFO>; 149 }; 150 151 dai-link-2 { 152 sound-dai = <&aiu AIU_CPU CPU_I2S_ENCODER>; 153 dai-format = "i2s"; 154 mclk-fs = <256>; 155 156 codec-0 { 157 sound-dai = <&aiu AIU_HDMI CTRL_I2S>; 158 }; 159 160 codec-1 { 161 sound-dai = <&aiu AIU_ACODEC CTRL_I2S>; 162 }; 163 }; 164 165 dai-link-3 { 166 sound-dai = <&aiu AIU_CPU CPU_SPDIF_ENCODER>; 167 168 codec-0 { 169 sound-dai = <&spdif_dit>; 170 }; 171 }; 172 173 dai-link-4 { 174 sound-dai = <&aiu AIU_HDMI CTRL_OUT>; 175 176 codec-0 { 177 sound-dai = <&hdmi_tx>; 178 }; 179 }; 180 181 dai-link-5 { 182 sound-dai = <&aiu AIU_ACODEC CTRL_OUT>; 183 184 codec-0 { 185 sound-dai = <&acodec>; 186 }; 187 }; 188 }; 189 }; 190 191 &acodec { 192 AVDD-supply = <&vddio_ao18>; 193 status = "okay"; 194 }; 195 196 &aiu { 197 status = "okay"; 198 pinctrl-0 = <&spdif_out_h_pins>; 199 pinctrl-names = "default"; 200 201 }; 202 203 &cec_AO { 204 status = "okay"; 205 pinctrl-0 = <&ao_cec_pins>; 206 pinctrl-names = "default"; 207 hdmi-phandle = <&hdmi_tx>; 208 }; 209 210 &cvbs_vdac_port { 211 cvbs_vdac_out: endpoint { 212 remote-endpoint = <&cvbs_connector_in>; 213 }; 214 }; 215 216 ðmac { 217 status = "okay"; 218 }; 219 220 &hdmi_tx { 221 status = "okay"; 222 pinctrl-0 = <&hdmi_hpd_pins>, <&hdmi_i2c_pins>; 223 pinctrl-names = "default"; 224 hdmi-supply = <&hdmi_5v>; 225 }; 226 227 &hdmi_tx_tmds_port { 228 hdmi_tx_tmds_out: endpoint { 229 remote-endpoint = <&hdmi_connector_in>; 230 }; 231 }; 232 233 &ir { 234 status = "okay"; 235 pinctrl-0 = <&remote_input_ao_pins>; 236 pinctrl-names = "default"; 237 }; 238 239 &pwm_ef { 240 status = "okay"; 241 pinctrl-0 = <&pwm_e_pins>; 242 pinctrl-names = "default"; 243 clocks = <&clkc CLKID_FCLK_DIV4>; 244 clock-names = "clkin0"; 245 }; 246 247 &saradc { 248 status = "okay"; 249 vref-supply = <&vddio_ao18>; 250 }; 251 252 /* Wireless SDIO Module */ 253 &sd_emmc_a { 254 status = "okay"; 255 pinctrl-0 = <&sdio_pins>; 256 pinctrl-1 = <&sdio_clk_gate_pins>; 257 pinctrl-names = "default", "clk-gate"; 258 #address-cells = <1>; 259 #size-cells = <0>; 260 261 bus-width = <4>; 262 cap-sd-highspeed; 263 max-frequency = <50000000>; 264 265 non-removable; 266 disable-wp; 267 268 /* WiFi firmware requires power to be kept while in suspend */ 269 keep-power-in-suspend; 270 271 mmc-pwrseq = <&sdio_pwrseq>; 272 273 vmmc-supply = <&vddao_3v3>; 274 vqmmc-supply = <&vddio_boot>; 275 }; 276 277 /* SD card */ 278 &sd_emmc_b { 279 status = "okay"; 280 pinctrl-0 = <&sdcard_pins>; 281 pinctrl-1 = <&sdcard_clk_gate_pins>; 282 pinctrl-names = "default", "clk-gate"; 283 284 bus-width = <4>; 285 cap-sd-highspeed; 286 max-frequency = <50000000>; 287 disable-wp; 288 289 cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_LOW>; 290 291 vmmc-supply = <&vddao_3v3>; 292 vqmmc-supply = <&vddio_boot>; 293 }; 294 295 /* eMMC */ 296 &sd_emmc_c { 297 status = "okay"; 298 pinctrl-0 = <&emmc_pins>, <&emmc_ds_pins>; 299 pinctrl-1 = <&emmc_clk_gate_pins>; 300 pinctrl-names = "default", "clk-gate"; 301 302 bus-width = <8>; 303 cap-mmc-highspeed; 304 max-frequency = <200000000>; 305 non-removable; 306 disable-wp; 307 mmc-ddr-1_8v; 308 mmc-hs200-1_8v; 309 310 mmc-pwrseq = <&emmc_pwrseq>; 311 vmmc-supply = <&vcc_3v3>; 312 vqmmc-supply = <&vddio_boot>; 313 }; 314 315 /* This UART is brought out to the DB9 connector */ 316 &uart_AO { 317 status = "okay"; 318 pinctrl-0 = <&uart_ao_a_pins>; 319 pinctrl-names = "default"; 320 }; 321 322 &usb { 323 status = "okay"; 324 dr_mode = "otg"; 325 };
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.