|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only OR MIT |
| 2 | +// Copyright (C) 2025 J. Neuschäfer < [email protected]> |
| 3 | + |
| 4 | +/dts-v1/; |
| 5 | + |
| 6 | +#include <dt-bindings/gpio/gpio.h> |
| 7 | +#include <dt-bindings/input/linux-event-codes.h> |
| 8 | +#include <dt-bindings/leds/common.h> |
| 9 | + |
| 10 | +#include "meson8.dtsi" |
| 11 | + |
| 12 | +/ { |
| 13 | + model = "Fernsehfee 3.0"; |
| 14 | + compatible = "tcu,fernsehfee3", "amlogic,meson8"; |
| 15 | + |
| 16 | + aliases { |
| 17 | + serial0 = &uart_AO; |
| 18 | + gpiochip0 = &gpio; |
| 19 | + gpiochip1 = &gpio_ao; |
| 20 | + i2c0 = &i2c_AO; |
| 21 | + i2c1 = &i2c_B; |
| 22 | + mmc0 = &sdhc; |
| 23 | + mmc1 = &sdio; |
| 24 | + }; |
| 25 | + |
| 26 | + chosen { |
| 27 | + stdout-path = "serial0:115200n8"; |
| 28 | + }; |
| 29 | + |
| 30 | + memory@0 { |
| 31 | + device_type = "memory"; |
| 32 | + reg = <0x0 0x40000000>; /* 1 GiB */ |
| 33 | + }; |
| 34 | + |
| 35 | + gpio-keys { |
| 36 | + compatible = "gpio-keys-polled"; |
| 37 | + poll-interval = <100>; |
| 38 | + |
| 39 | + power-button { |
| 40 | + label = "Power button"; |
| 41 | + linux,code = <KEY_POWER>; |
| 42 | + gpios = <&gpio_ao GPIOAO_3 GPIO_ACTIVE_LOW>; |
| 43 | + }; |
| 44 | + }; |
| 45 | + |
| 46 | + leds { |
| 47 | + compatible = "gpio-leds"; |
| 48 | + |
| 49 | + led-0 { |
| 50 | + /* |
| 51 | + * The power LED can be turned red, otherwise it is green. |
| 52 | + */ |
| 53 | + gpios = <&gpio_ao GPIO_TEST_N GPIO_ACTIVE_LOW>; |
| 54 | + function = LED_FUNCTION_POWER; |
| 55 | + color = <LED_COLOR_ID_RED>; |
| 56 | + }; |
| 57 | + }; |
| 58 | + |
| 59 | + vcc_5v: regulator-5v { |
| 60 | + /* 5V rail, always on as long as the system is running */ |
| 61 | + compatible = "regulator-fixed"; |
| 62 | + regulator-name = "5V"; |
| 63 | + regulator-min-microvolt = <5000000>; |
| 64 | + regulator-max-microvolt = <5000000>; |
| 65 | + regulator-always-on; |
| 66 | + }; |
| 67 | + |
| 68 | + vcc_3v3: regulator-3v3 { |
| 69 | + /* Chipown AP2420 step-down converter */ |
| 70 | + compatible = "regulator-fixed"; |
| 71 | + regulator-name = "3.3V"; |
| 72 | + regulator-min-microvolt = <3300000>; |
| 73 | + regulator-max-microvolt = <3300000>; |
| 74 | + vin-supply = <&vcc_5v>; |
| 75 | + }; |
| 76 | + |
| 77 | + wifi_3v3: regulator-wifi { |
| 78 | + compatible = "regulator-fixed"; |
| 79 | + regulator-name = "3.3V-WIFI"; |
| 80 | + regulator-min-microvolt = <3300000>; |
| 81 | + regulator-max-microvolt = <3300000>; |
| 82 | + vin-supply = <&vcc_3v3>; |
| 83 | + gpio = <&gpio GPIOX_11 GPIO_ACTIVE_HIGH>; |
| 84 | + enable-active-high; |
| 85 | + }; |
| 86 | +}; |
| 87 | + |
| 88 | +&cpu0 { |
| 89 | + cpu-supply = <&vcck>; |
| 90 | +}; |
| 91 | + |
| 92 | +ðmac { |
| 93 | + status = "okay"; |
| 94 | + pinctrl-0 = <ð_pins>; |
| 95 | + pinctrl-names = "default"; |
| 96 | + phy-handle = <ð_phy0>; |
| 97 | + phy-mode = "rmii"; |
| 98 | + |
| 99 | + mdio { |
| 100 | + compatible = "snps,dwmac-mdio"; |
| 101 | + #address-cells = <1>; |
| 102 | + #size-cells = <0>; |
| 103 | + |
| 104 | + eth_phy0: ethernet-phy@0 { |
| 105 | + /* IC Plus IP101A (0x02430c54) */ |
| 106 | + reg = <0>; |
| 107 | + |
| 108 | + reset-assert-us = <10000>; |
| 109 | + reset-deassert-us = <10000>; |
| 110 | + reset-gpios = <&gpio GPIOH_4 GPIO_ACTIVE_LOW>; |
| 111 | + }; |
| 112 | + }; |
| 113 | +}; |
| 114 | + |
| 115 | +&i2c_AO { |
| 116 | + status = "okay"; |
| 117 | + pinctrl-0 = <&i2c_ao_pins>; |
| 118 | + pinctrl-names = "default"; |
| 119 | + |
| 120 | + pmic@32 { |
| 121 | + compatible = "ricoh,rn5t618"; |
| 122 | + reg = <0x32>; |
| 123 | + system-power-controller; |
| 124 | + |
| 125 | + regulators { |
| 126 | + vcck: DCDC1 { |
| 127 | + regulator-name = "VCCK"; |
| 128 | + regulator-min-microvolt = <825000>; |
| 129 | + regulator-max-microvolt = <1150000>; |
| 130 | + regulator-boot-on; |
| 131 | + regulator-always-on; |
| 132 | + }; |
| 133 | + |
| 134 | + vddee: DCDC2 { |
| 135 | + /* the output is also used as VDDAO */ |
| 136 | + regulator-name = "VDD_EE"; |
| 137 | + regulator-min-microvolt = <950000>; |
| 138 | + regulator-max-microvolt = <1150000>; |
| 139 | + regulator-boot-on; |
| 140 | + regulator-always-on; |
| 141 | + }; |
| 142 | + |
| 143 | + DCDC3 { |
| 144 | + regulator-name = "VDD_DDR"; |
| 145 | + regulator-min-microvolt = <1500000>; |
| 146 | + regulator-max-microvolt = <1500000>; |
| 147 | + regulator-boot-on; |
| 148 | + regulator-always-on; |
| 149 | + }; |
| 150 | + |
| 151 | + LDO1 { |
| 152 | + regulator-name = "VDDIO_AO28"; |
| 153 | + regulator-min-microvolt = <2900000>; |
| 154 | + regulator-max-microvolt = <2900000>; |
| 155 | + regulator-boot-on; |
| 156 | + regulator-always-on; |
| 157 | + }; |
| 158 | + |
| 159 | + LDO2 { |
| 160 | + regulator-name = "VDDIO_AO18"; |
| 161 | + regulator-min-microvolt = <1800000>; |
| 162 | + regulator-max-microvolt = <1800000>; |
| 163 | + regulator-boot-on; |
| 164 | + regulator-always-on; |
| 165 | + }; |
| 166 | + |
| 167 | + vcc1v8_usb: LDO3 { |
| 168 | + regulator-name = "VCC1V8_USB"; |
| 169 | + regulator-min-microvolt = <1800000>; |
| 170 | + regulator-max-microvolt = <1800000>; |
| 171 | + regulator-boot-on; |
| 172 | + }; |
| 173 | + |
| 174 | + LDO4 { |
| 175 | + /* This one appears to be unused */ |
| 176 | + regulator-name = "VCC2V8"; |
| 177 | + regulator-min-microvolt = <2850000>; |
| 178 | + regulator-max-microvolt = <2850000>; |
| 179 | + }; |
| 180 | + |
| 181 | + LDO5 { |
| 182 | + regulator-name = "AVDD1V8"; |
| 183 | + regulator-min-microvolt = <1800000>; |
| 184 | + regulator-max-microvolt = <1800000>; |
| 185 | + regulator-boot-on; |
| 186 | + regulator-always-on; |
| 187 | + }; |
| 188 | + |
| 189 | + LDORTC1 { |
| 190 | + regulator-name = "VDD_LDO"; |
| 191 | + regulator-min-microvolt = <2700000>; |
| 192 | + regulator-max-microvolt = <2700000>; |
| 193 | + regulator-boot-on; |
| 194 | + regulator-always-on; |
| 195 | + }; |
| 196 | + |
| 197 | + LDORTC2 { |
| 198 | + regulator-name = "RTC_0V9"; |
| 199 | + regulator-min-microvolt = <900000>; |
| 200 | + regulator-max-microvolt = <900000>; |
| 201 | + regulator-boot-on; |
| 202 | + regulator-always-on; |
| 203 | + }; |
| 204 | + }; |
| 205 | + }; |
| 206 | + |
| 207 | + eeprom@50 { |
| 208 | + /* Fairchild FM24C08A */ |
| 209 | + compatible = "atmel,24c08"; |
| 210 | + reg = <0x50>; |
| 211 | + pagesize = <16>; |
| 212 | + wp-gpios = <&gpio GPIOH_3 GPIO_ACTIVE_HIGH>; |
| 213 | + num-addresses = <4>; |
| 214 | + }; |
| 215 | +}; |
| 216 | + |
| 217 | +&i2c_B { |
| 218 | + status = "okay"; |
| 219 | + pinctrl-0 = <&i2c_b_pins>; |
| 220 | + pinctrl-names = "default"; |
| 221 | + |
| 222 | + /* TODO: SiI9293 HDMI receiver @ 0x39 */ |
| 223 | +}; |
| 224 | + |
| 225 | +&mali { |
| 226 | + mali-supply = <&vddee>; |
| 227 | +}; |
| 228 | + |
| 229 | +&sdhc { |
| 230 | + status = "okay"; |
| 231 | + pinctrl-0 = <&sdxc_c_pins>; |
| 232 | + pinctrl-names = "default"; |
| 233 | + |
| 234 | + /* eMMC */ |
| 235 | + bus-width = <8>; |
| 236 | + max-frequency = <100000000>; |
| 237 | + |
| 238 | + disable-wp; |
| 239 | + cap-mmc-highspeed; |
| 240 | + mmc-hs200-1_8v; |
| 241 | + no-sdio; |
| 242 | + |
| 243 | + vmmc-supply = <&vcc_3v3>; |
| 244 | + vqmmc-supply = <&vcc_3v3>; |
| 245 | +}; |
| 246 | + |
| 247 | +&sdio { |
| 248 | + status = "okay"; |
| 249 | + pinctrl-0 = <&sd_b_pins>; |
| 250 | + |
| 251 | + /* SD card */ |
| 252 | + slot@1 { |
| 253 | + compatible = "mmc-slot"; |
| 254 | + reg = <1>; |
| 255 | + status = "okay"; |
| 256 | + |
| 257 | + bus-width = <4>; |
| 258 | + cap-mmc-highspeed; |
| 259 | + cap-sd-highspeed; |
| 260 | + disable-wp; |
| 261 | + |
| 262 | + cd-gpios = <&gpio CARD_6 GPIO_ACTIVE_LOW>; |
| 263 | + |
| 264 | + vmmc-supply = <&vcc_3v3>; |
| 265 | + }; |
| 266 | +}; |
| 267 | + |
| 268 | +&uart_AO { |
| 269 | + status = "okay"; |
| 270 | + pinctrl-0 = <&uart_ao_a_pins>; |
| 271 | + pinctrl-names = "default"; |
| 272 | +}; |
| 273 | + |
| 274 | +&usb0 { |
| 275 | + status = "okay"; |
| 276 | +}; |
| 277 | + |
| 278 | +&usb0_phy { |
| 279 | + status = "okay"; |
| 280 | + phy-supply = <&vcc1v8_usb>; |
| 281 | +}; |
| 282 | + |
| 283 | +&usb1 { |
| 284 | + status = "okay"; |
| 285 | + dr_mode = "host"; |
| 286 | + #address-cells = <1>; |
| 287 | + #size-cells = <0>; |
| 288 | + |
| 289 | + wifi: wifi@1 { |
| 290 | + /* Realtek RTL8188 2.4GHz WiFi module */ |
| 291 | + compatible = "usbbda,179"; |
| 292 | + reg = <1>; |
| 293 | + vdd-supply = <&wifi_3v3>; |
| 294 | + }; |
| 295 | +}; |
| 296 | + |
| 297 | +&usb1_phy { |
| 298 | + status = "okay"; |
| 299 | + phy-supply = <&vcc1v8_usb>; |
| 300 | +}; |
| 301 | + |
| 302 | +&ir_receiver { |
| 303 | + status = "okay"; |
| 304 | + pinctrl-0 = <&ir_recv_pins>; |
| 305 | + pinctrl-names = "default"; |
| 306 | +}; |
0 commit comments