1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) << 2 /* 1 /* 3 * Copyright (c) 2016 Andreas Färber 2 * Copyright (c) 2016 Andreas Färber 4 * Copyright (c) 2016 BayLibre, Inc. 3 * Copyright (c) 2016 BayLibre, Inc. 5 * Author: Kevin Hilman <khilman@kernel.org> 4 * Author: Kevin Hilman <khilman@kernel.org> >> 5 * >> 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 >> 9 * whole. >> 10 * >> 11 * a) This library 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. >> 15 * >> 16 * This library 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. >> 20 * >> 21 * Or, alternatively, >> 22 * >> 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 >> 30 * conditions: >> 31 * >> 32 * The above copyright notice and this permission notice shall be >> 33 * included in all copies or substantial portions of the Software. >> 34 * >> 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. 6 */ 43 */ 7 44 8 #include "meson-gxbb.dtsi" 45 #include "meson-gxbb.dtsi" 9 46 10 / { 47 / { 11 aliases { 48 aliases { 12 serial0 = &uart_AO; 49 serial0 = &uart_AO; 13 ethernet0 = ðmac; << 14 }; 50 }; 15 51 16 chosen { 52 chosen { 17 stdout-path = "serial0:115200n 53 stdout-path = "serial0:115200n8"; 18 }; 54 }; 19 55 20 memory@0 { 56 memory@0 { 21 device_type = "memory"; 57 device_type = "memory"; 22 reg = <0x0 0x0 0x0 0x40000000> 58 reg = <0x0 0x0 0x0 0x40000000>; 23 }; 59 }; 24 60 25 usb_pwr: regulator-usb-pwrs { 61 usb_pwr: regulator-usb-pwrs { 26 compatible = "regulator-fixed" 62 compatible = "regulator-fixed"; 27 63 28 regulator-name = "USB_PWR"; 64 regulator-name = "USB_PWR"; 29 65 30 regulator-min-microvolt = <500 66 regulator-min-microvolt = <5000000>; 31 regulator-max-microvolt = <500 67 regulator-max-microvolt = <5000000>; 32 68 33 /* signal name in schematic: U 69 /* signal name in schematic: USB_PWR_EN */ 34 gpio = <&gpio GPIODV_24 GPIO_A 70 gpio = <&gpio GPIODV_24 GPIO_ACTIVE_HIGH>; 35 enable-active-high; 71 enable-active-high; 36 }; 72 }; 37 73 38 vddio_card: gpio-regulator { 74 vddio_card: gpio-regulator { 39 compatible = "regulator-gpio"; 75 compatible = "regulator-gpio"; 40 76 41 regulator-name = "VDDIO_CARD"; 77 regulator-name = "VDDIO_CARD"; 42 regulator-min-microvolt = <180 78 regulator-min-microvolt = <1800000>; 43 regulator-max-microvolt = <330 79 regulator-max-microvolt = <3300000>; 44 80 45 gpios = <&gpio_ao GPIOAO_5 GPI 81 gpios = <&gpio_ao GPIOAO_5 GPIO_ACTIVE_HIGH>; 46 gpios-states = <1>; 82 gpios-states = <1>; 47 83 48 /* Based on P200 schematics, s 84 /* Based on P200 schematics, signal CARD_1.8V/3.3V_CTR */ 49 states = <1800000 0>, !! 85 states = <1800000 0 50 <3300000 1>; !! 86 3300000 1>; 51 << 52 regulator-settling-time-up-us << 53 regulator-settling-time-down-u << 54 }; 87 }; 55 88 56 vddio_boot: regulator-vddio-boot { !! 89 vddio_boot: regulator-vddio_boot { 57 compatible = "regulator-fixed" 90 compatible = "regulator-fixed"; 58 regulator-name = "VDDIO_BOOT"; 91 regulator-name = "VDDIO_BOOT"; 59 regulator-min-microvolt = <180 92 regulator-min-microvolt = <1800000>; 60 regulator-max-microvolt = <180 93 regulator-max-microvolt = <1800000>; 61 }; 94 }; 62 95 63 vddao_3v3: regulator-vddao-3v3 { !! 96 vddao_3v3: regulator-vddao_3v3 { 64 compatible = "regulator-fixed" 97 compatible = "regulator-fixed"; 65 regulator-name = "VDDAO_3V3"; 98 regulator-name = "VDDAO_3V3"; 66 regulator-min-microvolt = <330 99 regulator-min-microvolt = <3300000>; 67 regulator-max-microvolt = <330 100 regulator-max-microvolt = <3300000>; 68 }; 101 }; 69 102 70 vcc_3v3: regulator-vcc-3v3 { !! 103 vcc_3v3: regulator-vcc_3v3 { 71 compatible = "regulator-fixed" 104 compatible = "regulator-fixed"; 72 regulator-name = "VCC_3V3"; 105 regulator-name = "VCC_3V3"; 73 regulator-min-microvolt = <330 106 regulator-min-microvolt = <3300000>; 74 regulator-max-microvolt = <330 107 regulator-max-microvolt = <3300000>; 75 }; 108 }; 76 109 77 emmc_pwrseq: emmc-pwrseq { 110 emmc_pwrseq: emmc-pwrseq { 78 compatible = "mmc-pwrseq-emmc" 111 compatible = "mmc-pwrseq-emmc"; 79 reset-gpios = <&gpio BOOT_9 GP 112 reset-gpios = <&gpio BOOT_9 GPIO_ACTIVE_LOW>; 80 }; 113 }; 81 114 82 wifi32k: wifi32k { 115 wifi32k: wifi32k { 83 compatible = "pwm-clock"; 116 compatible = "pwm-clock"; 84 #clock-cells = <0>; 117 #clock-cells = <0>; 85 clock-frequency = <32768>; 118 clock-frequency = <32768>; 86 pwms = <&pwm_ef 0 30518 0>; /* 119 pwms = <&pwm_ef 0 30518 0>; /* PWM_E at 32.768KHz */ 87 }; 120 }; 88 121 89 sdio_pwrseq: sdio-pwrseq { 122 sdio_pwrseq: sdio-pwrseq { 90 compatible = "mmc-pwrseq-simpl 123 compatible = "mmc-pwrseq-simple"; 91 reset-gpios = <&gpio GPIOX_6 G 124 reset-gpios = <&gpio GPIOX_6 GPIO_ACTIVE_LOW>; 92 clocks = <&wifi32k>; 125 clocks = <&wifi32k>; 93 clock-names = "ext_clock"; 126 clock-names = "ext_clock"; 94 }; 127 }; 95 128 96 cvbs_connector: cvbs-connector { 129 cvbs_connector: cvbs-connector { 97 compatible = "composite-video- 130 compatible = "composite-video-connector"; 98 131 99 port { 132 port { 100 cvbs_connector_in: end 133 cvbs_connector_in: endpoint { 101 remote-endpoin 134 remote-endpoint = <&cvbs_vdac_out>; 102 }; 135 }; 103 }; 136 }; 104 }; 137 }; 105 138 106 hdmi-connector { 139 hdmi-connector { 107 compatible = "hdmi-connector"; 140 compatible = "hdmi-connector"; 108 type = "a"; 141 type = "a"; 109 142 110 port { 143 port { 111 hdmi_connector_in: end 144 hdmi_connector_in: endpoint { 112 remote-endpoin 145 remote-endpoint = <&hdmi_tx_tmds_out>; 113 }; 146 }; 114 }; 147 }; 115 }; 148 }; 116 }; 149 }; 117 150 118 &cec_AO { << 119 status = "okay"; << 120 pinctrl-0 = <&ao_cec_pins>; << 121 pinctrl-names = "default"; << 122 hdmi-phandle = <&hdmi_tx>; << 123 }; << 124 << 125 &cvbs_vdac_port { 151 &cvbs_vdac_port { 126 cvbs_vdac_out: endpoint { 152 cvbs_vdac_out: endpoint { 127 remote-endpoint = <&cvbs_conne 153 remote-endpoint = <&cvbs_connector_in>; 128 }; 154 }; 129 }; 155 }; 130 156 131 &hdmi_tx { 157 &hdmi_tx { 132 status = "okay"; 158 status = "okay"; 133 pinctrl-0 = <&hdmi_hpd_pins>, <&hdmi_i 159 pinctrl-0 = <&hdmi_hpd_pins>, <&hdmi_i2c_pins>; 134 pinctrl-names = "default"; 160 pinctrl-names = "default"; 135 }; 161 }; 136 162 137 &hdmi_tx_tmds_port { 163 &hdmi_tx_tmds_port { 138 hdmi_tx_tmds_out: endpoint { 164 hdmi_tx_tmds_out: endpoint { 139 remote-endpoint = <&hdmi_conne 165 remote-endpoint = <&hdmi_connector_in>; 140 }; 166 }; 141 }; 167 }; 142 168 143 &ir { 169 &ir { 144 status = "okay"; 170 status = "okay"; 145 pinctrl-0 = <&remote_input_ao_pins>; 171 pinctrl-0 = <&remote_input_ao_pins>; 146 pinctrl-names = "default"; 172 pinctrl-names = "default"; 147 }; 173 }; 148 174 149 &pwm_ef { 175 &pwm_ef { 150 status = "okay"; 176 status = "okay"; 151 pinctrl-0 = <&pwm_e_pins>; 177 pinctrl-0 = <&pwm_e_pins>; 152 pinctrl-names = "default"; 178 pinctrl-names = "default"; 153 clocks = <&clkc CLKID_FCLK_DIV4>; 179 clocks = <&clkc CLKID_FCLK_DIV4>; 154 clock-names = "clkin0"; 180 clock-names = "clkin0"; 155 }; 181 }; 156 182 157 /* Wireless SDIO Module */ 183 /* Wireless SDIO Module */ 158 &sd_emmc_a { 184 &sd_emmc_a { 159 status = "okay"; 185 status = "okay"; 160 pinctrl-0 = <&sdio_pins>; 186 pinctrl-0 = <&sdio_pins>; 161 pinctrl-1 = <&sdio_clk_gate_pins>; !! 187 pinctrl-names = "default"; 162 pinctrl-names = "default", "clk-gate"; << 163 #address-cells = <1>; 188 #address-cells = <1>; 164 #size-cells = <0>; 189 #size-cells = <0>; 165 190 166 bus-width = <4>; 191 bus-width = <4>; 167 cap-sd-highspeed; 192 cap-sd-highspeed; 168 max-frequency = <50000000>; !! 193 max-frequency = <100000000>; 169 194 170 non-removable; 195 non-removable; 171 disable-wp; 196 disable-wp; 172 197 173 /* WiFi firmware requires power to be << 174 keep-power-in-suspend; << 175 << 176 mmc-pwrseq = <&sdio_pwrseq>; 198 mmc-pwrseq = <&sdio_pwrseq>; 177 199 178 vmmc-supply = <&vddao_3v3>; 200 vmmc-supply = <&vddao_3v3>; 179 vqmmc-supply = <&vddio_boot>; 201 vqmmc-supply = <&vddio_boot>; 180 202 181 brcmf: wifi@1 { 203 brcmf: wifi@1 { 182 reg = <1>; 204 reg = <1>; 183 compatible = "brcm,bcm4329-fma 205 compatible = "brcm,bcm4329-fmac"; 184 }; 206 }; 185 }; 207 }; 186 208 187 /* SD card */ 209 /* SD card */ 188 &sd_emmc_b { 210 &sd_emmc_b { 189 status = "okay"; 211 status = "okay"; 190 pinctrl-0 = <&sdcard_pins>; 212 pinctrl-0 = <&sdcard_pins>; 191 pinctrl-1 = <&sdcard_clk_gate_pins>; !! 213 pinctrl-names = "default"; 192 pinctrl-names = "default", "clk-gate"; << 193 214 194 bus-width = <4>; 215 bus-width = <4>; 195 cap-sd-highspeed; 216 cap-sd-highspeed; 196 sd-uhs-sdr12; << 197 sd-uhs-sdr25; << 198 sd-uhs-sdr50; << 199 max-frequency = <100000000>; 217 max-frequency = <100000000>; 200 disable-wp; 218 disable-wp; 201 219 202 cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_L !! 220 cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_HIGH>; >> 221 cd-inverted; 203 222 204 vmmc-supply = <&vddao_3v3>; 223 vmmc-supply = <&vddao_3v3>; 205 vqmmc-supply = <&vddio_card>; 224 vqmmc-supply = <&vddio_card>; 206 }; 225 }; 207 226 208 /* eMMC */ 227 /* eMMC */ 209 &sd_emmc_c { 228 &sd_emmc_c { 210 status = "okay"; 229 status = "okay"; 211 pinctrl-0 = <&emmc_pins>, <&emmc_ds_pi !! 230 pinctrl-0 = <&emmc_pins>; 212 pinctrl-1 = <&emmc_clk_gate_pins>; !! 231 pinctrl-names = "default"; 213 pinctrl-names = "default", "clk-gate"; << 214 232 215 bus-width = <8>; 233 bus-width = <8>; >> 234 cap-sd-highspeed; 216 cap-mmc-highspeed; 235 cap-mmc-highspeed; 217 max-frequency = <200000000>; 236 max-frequency = <200000000>; 218 non-removable; 237 non-removable; 219 disable-wp; 238 disable-wp; 220 mmc-ddr-1_8v; 239 mmc-ddr-1_8v; 221 mmc-hs200-1_8v; 240 mmc-hs200-1_8v; 222 241 223 mmc-pwrseq = <&emmc_pwrseq>; 242 mmc-pwrseq = <&emmc_pwrseq>; 224 vmmc-supply = <&vcc_3v3>; 243 vmmc-supply = <&vcc_3v3>; 225 vqmmc-supply = <&vddio_boot>; 244 vqmmc-supply = <&vddio_boot>; 226 }; 245 }; 227 246 228 /* This UART is brought out to the DB9 connect 247 /* This UART is brought out to the DB9 connector */ 229 &uart_AO { 248 &uart_AO { 230 status = "okay"; 249 status = "okay"; 231 pinctrl-0 = <&uart_ao_a_pins>; 250 pinctrl-0 = <&uart_ao_a_pins>; 232 pinctrl-names = "default"; 251 pinctrl-names = "default"; 233 }; 252 }; 234 253 235 &usb0_phy { 254 &usb0_phy { 236 status = "okay"; 255 status = "okay"; 237 phy-supply = <&usb_pwr>; 256 phy-supply = <&usb_pwr>; 238 }; 257 }; 239 258 240 &usb1_phy { 259 &usb1_phy { 241 status = "okay"; 260 status = "okay"; 242 }; 261 }; 243 262 244 &usb0 { 263 &usb0 { 245 status = "okay"; 264 status = "okay"; 246 }; 265 }; 247 266 248 &usb1 { 267 &usb1 { 249 status = "okay"; 268 status = "okay"; 250 }; 269 };
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.