1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2 /* 2 /* 3 * Copyright (c) 2019 Shenzhen Wesion Technolo 3 * Copyright (c) 2019 Shenzhen Wesion Technology Co., Ltd. 4 * (https://www.khadas.com) 4 * (https://www.khadas.com) 5 */ 5 */ 6 6 7 /dts-v1/; 7 /dts-v1/; 8 #include <dt-bindings/input/linux-event-codes. 8 #include <dt-bindings/input/linux-event-codes.h> 9 #include <dt-bindings/interrupt-controller/irq << 10 #include <dt-bindings/pwm/pwm.h> 9 #include <dt-bindings/pwm/pwm.h> 11 #include "rk3399.dtsi" 10 #include "rk3399.dtsi" >> 11 #include "rk3399-opp.dtsi" 12 12 13 / { 13 / { 14 aliases { << 15 mmc0 = &sdio0; << 16 mmc1 = &sdmmc; << 17 mmc2 = &sdhci; << 18 }; << 19 << 20 chosen { 14 chosen { 21 stdout-path = "serial2:1500000 15 stdout-path = "serial2:1500000n8"; 22 }; 16 }; 23 17 24 clkin_gmac: external-gmac-clock { 18 clkin_gmac: external-gmac-clock { 25 compatible = "fixed-clock"; 19 compatible = "fixed-clock"; 26 clock-frequency = <125000000>; 20 clock-frequency = <125000000>; 27 clock-output-names = "clkin_gm 21 clock-output-names = "clkin_gmac"; 28 #clock-cells = <0>; 22 #clock-cells = <0>; 29 }; 23 }; 30 24 31 sdio_pwrseq: sdio-pwrseq { 25 sdio_pwrseq: sdio-pwrseq { 32 compatible = "mmc-pwrseq-simpl 26 compatible = "mmc-pwrseq-simple"; 33 clocks = <&rk808 1>; 27 clocks = <&rk808 1>; 34 clock-names = "ext_clock"; 28 clock-names = "ext_clock"; 35 pinctrl-names = "default"; 29 pinctrl-names = "default"; 36 pinctrl-0 = <&wifi_enable_h>; 30 pinctrl-0 = <&wifi_enable_h>; 37 31 38 /* 32 /* 39 * On the module itself this i 33 * On the module itself this is one of these (depending 40 * on the actual card populate 34 * on the actual card populated): 41 * - SDIO_RESET_L_WL_REG_ON 35 * - SDIO_RESET_L_WL_REG_ON 42 * - PDN (power down when low) 36 * - PDN (power down when low) 43 */ 37 */ 44 reset-gpios = <&gpio2 RK_PD4 G 38 reset-gpios = <&gpio2 RK_PD4 GPIO_ACTIVE_LOW>; 45 }; 39 }; 46 40 47 /* switched by pmic_sleep */ 41 /* switched by pmic_sleep */ 48 vcc1v8_s3: vcca1v8_s3: vcc1v8-s3 { 42 vcc1v8_s3: vcca1v8_s3: vcc1v8-s3 { 49 compatible = "regulator-fixed" 43 compatible = "regulator-fixed"; 50 regulator-name = "vcc1v8_s3"; 44 regulator-name = "vcc1v8_s3"; 51 regulator-always-on; 45 regulator-always-on; 52 regulator-boot-on; 46 regulator-boot-on; 53 regulator-min-microvolt = <180 47 regulator-min-microvolt = <1800000>; 54 regulator-max-microvolt = <180 48 regulator-max-microvolt = <1800000>; 55 vin-supply = <&vcc_1v8>; 49 vin-supply = <&vcc_1v8>; 56 }; 50 }; 57 51 58 vcc3v3_pcie: vcc3v3-pcie-regulator { 52 vcc3v3_pcie: vcc3v3-pcie-regulator { 59 compatible = "regulator-fixed" 53 compatible = "regulator-fixed"; 60 regulator-name = "vcc3v3_pcie" 54 regulator-name = "vcc3v3_pcie"; 61 regulator-always-on; 55 regulator-always-on; 62 regulator-boot-on; 56 regulator-boot-on; 63 regulator-min-microvolt = <330 57 regulator-min-microvolt = <3300000>; 64 regulator-max-microvolt = <330 58 regulator-max-microvolt = <3300000>; 65 vin-supply = <&vsys_3v3>; 59 vin-supply = <&vsys_3v3>; 66 }; 60 }; 67 61 68 /* Actually 3 regulators (host0, 1, 2) 62 /* Actually 3 regulators (host0, 1, 2) controlled by the same gpio */ 69 vcc5v0_host: vcc5v0-host-regulator { 63 vcc5v0_host: vcc5v0-host-regulator { 70 compatible = "regulator-fixed" 64 compatible = "regulator-fixed"; 71 enable-active-high; 65 enable-active-high; 72 gpio = <&gpio4 RK_PD1 GPIO_ACT 66 gpio = <&gpio4 RK_PD1 GPIO_ACTIVE_HIGH>; 73 pinctrl-names = "default"; 67 pinctrl-names = "default"; 74 pinctrl-0 = <&vcc5v0_host_en>; 68 pinctrl-0 = <&vcc5v0_host_en>; 75 regulator-name = "vcc5v0_host" 69 regulator-name = "vcc5v0_host"; 76 regulator-always-on; 70 regulator-always-on; 77 vin-supply = <&vsys_5v0>; 71 vin-supply = <&vsys_5v0>; 78 }; 72 }; 79 73 80 vdd_log: vdd-log { 74 vdd_log: vdd-log { 81 compatible = "pwm-regulator"; 75 compatible = "pwm-regulator"; 82 pwms = <&pwm2 0 25000 1>; 76 pwms = <&pwm2 0 25000 1>; 83 pwm-supply = <&vsys_3v3>; << 84 regulator-name = "vdd_log"; 77 regulator-name = "vdd_log"; 85 regulator-always-on; 78 regulator-always-on; 86 regulator-boot-on; 79 regulator-boot-on; 87 regulator-min-microvolt = <800 80 regulator-min-microvolt = <800000>; 88 regulator-max-microvolt = <140 81 regulator-max-microvolt = <1400000>; >> 82 vin-supply = <&vsys_3v3>; 89 }; 83 }; 90 84 91 vsys: vsys { 85 vsys: vsys { 92 compatible = "regulator-fixed" 86 compatible = "regulator-fixed"; 93 regulator-name = "vsys"; 87 regulator-name = "vsys"; 94 regulator-always-on; 88 regulator-always-on; 95 regulator-boot-on; 89 regulator-boot-on; 96 }; 90 }; 97 91 98 vsys_3v3: vsys-3v3 { 92 vsys_3v3: vsys-3v3 { 99 compatible = "regulator-fixed" 93 compatible = "regulator-fixed"; 100 regulator-name = "vsys_3v3"; 94 regulator-name = "vsys_3v3"; 101 regulator-always-on; 95 regulator-always-on; 102 regulator-boot-on; 96 regulator-boot-on; 103 regulator-min-microvolt = <330 97 regulator-min-microvolt = <3300000>; 104 regulator-max-microvolt = <330 98 regulator-max-microvolt = <3300000>; 105 vin-supply = <&vsys>; 99 vin-supply = <&vsys>; 106 }; 100 }; 107 101 108 vsys_5v0: vsys-5v0 { 102 vsys_5v0: vsys-5v0 { 109 compatible = "regulator-fixed" 103 compatible = "regulator-fixed"; 110 regulator-name = "vsys_5v0"; 104 regulator-name = "vsys_5v0"; 111 regulator-always-on; 105 regulator-always-on; 112 regulator-boot-on; 106 regulator-boot-on; 113 regulator-min-microvolt = <500 107 regulator-min-microvolt = <5000000>; 114 regulator-max-microvolt = <500 108 regulator-max-microvolt = <5000000>; 115 vin-supply = <&vsys>; 109 vin-supply = <&vsys>; 116 }; 110 }; 117 111 118 adc-keys { 112 adc-keys { 119 compatible = "adc-keys"; 113 compatible = "adc-keys"; 120 io-channels = <&saradc 1>; 114 io-channels = <&saradc 1>; 121 io-channel-names = "buttons"; 115 io-channel-names = "buttons"; 122 keyup-threshold-microvolt = <1 116 keyup-threshold-microvolt = <1800000>; 123 poll-interval = <100>; 117 poll-interval = <100>; 124 118 125 button-recovery { !! 119 recovery { 126 label = "Recovery"; 120 label = "Recovery"; 127 linux,code = <KEY_VEND 121 linux,code = <KEY_VENDOR>; 128 press-threshold-microv 122 press-threshold-microvolt = <18000>; 129 }; 123 }; 130 }; 124 }; 131 125 132 gpio-keys { 126 gpio-keys { 133 compatible = "gpio-keys"; 127 compatible = "gpio-keys"; 134 autorepeat; 128 autorepeat; 135 pinctrl-names = "default"; 129 pinctrl-names = "default"; 136 pinctrl-0 = <&pwrbtn>; 130 pinctrl-0 = <&pwrbtn>; 137 131 138 key-power { !! 132 power { 139 debounce-interval = <1 133 debounce-interval = <100>; 140 gpios = <&gpio0 RK_PA5 134 gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_LOW>; 141 label = "GPIO Key Powe 135 label = "GPIO Key Power"; 142 linux,code = <KEY_POWE 136 linux,code = <KEY_POWER>; 143 wakeup-source; 137 wakeup-source; 144 }; 138 }; 145 }; 139 }; 146 140 147 ir-receiver { 141 ir-receiver { 148 compatible = "gpio-ir-receiver 142 compatible = "gpio-ir-receiver"; 149 gpios = <&gpio1 RK_PB6 GPIO_AC 143 gpios = <&gpio1 RK_PB6 GPIO_ACTIVE_LOW>; 150 linux,rc-map-name = "rc-khadas 144 linux,rc-map-name = "rc-khadas"; 151 pinctrl-names = "default"; 145 pinctrl-names = "default"; 152 pinctrl-0 = <&ir_rx>; 146 pinctrl-0 = <&ir_rx>; 153 }; 147 }; 154 148 155 leds { 149 leds { 156 compatible = "gpio-leds"; 150 compatible = "gpio-leds"; 157 pinctrl-names = "default"; 151 pinctrl-names = "default"; 158 pinctrl-0 = <&sys_led_pin>, <& 152 pinctrl-0 = <&sys_led_pin>, <&user_led_pin>; 159 153 160 sys_led: led-0 { 154 sys_led: led-0 { 161 label = "sys_led"; 155 label = "sys_led"; 162 linux,default-trigger 156 linux,default-trigger = "heartbeat"; 163 gpios = <&gpio0 RK_PA6 157 gpios = <&gpio0 RK_PA6 GPIO_ACTIVE_HIGH>; 164 }; 158 }; 165 159 166 user_led: led-1 { 160 user_led: led-1 { 167 label = "user_led"; 161 label = "user_led"; 168 default-state = "off"; 162 default-state = "off"; 169 gpios = <&gpio4 RK_PD0 163 gpios = <&gpio4 RK_PD0 GPIO_ACTIVE_HIGH>; 170 }; 164 }; 171 }; 165 }; 172 166 173 fan: pwm-fan { 167 fan: pwm-fan { 174 compatible = "pwm-fan"; 168 compatible = "pwm-fan"; 175 cooling-levels = <0 150 200 25 169 cooling-levels = <0 150 200 255>; 176 #cooling-cells = <2>; 170 #cooling-cells = <2>; 177 fan-supply = <&vsys_5v0>; 171 fan-supply = <&vsys_5v0>; 178 pwms = <&pwm0 0 40000 0>; 172 pwms = <&pwm0 0 40000 0>; 179 }; 173 }; 180 }; 174 }; 181 175 182 &cpu_l0 { 176 &cpu_l0 { 183 cpu-supply = <&vdd_cpu_l>; 177 cpu-supply = <&vdd_cpu_l>; 184 }; 178 }; 185 179 186 &cpu_l1 { 180 &cpu_l1 { 187 cpu-supply = <&vdd_cpu_l>; 181 cpu-supply = <&vdd_cpu_l>; 188 }; 182 }; 189 183 190 &cpu_l2 { 184 &cpu_l2 { 191 cpu-supply = <&vdd_cpu_l>; 185 cpu-supply = <&vdd_cpu_l>; 192 }; 186 }; 193 187 194 &cpu_l3 { 188 &cpu_l3 { 195 cpu-supply = <&vdd_cpu_l>; 189 cpu-supply = <&vdd_cpu_l>; 196 }; 190 }; 197 191 198 &cpu_b0 { 192 &cpu_b0 { 199 cpu-supply = <&vdd_cpu_b>; 193 cpu-supply = <&vdd_cpu_b>; 200 }; 194 }; 201 195 202 &cpu_b1 { 196 &cpu_b1 { 203 cpu-supply = <&vdd_cpu_b>; 197 cpu-supply = <&vdd_cpu_b>; 204 }; 198 }; 205 199 206 &cpu_thermal { 200 &cpu_thermal { 207 trips { 201 trips { 208 cpu_warm: cpu_warm { 202 cpu_warm: cpu_warm { 209 temperature = <55000>; 203 temperature = <55000>; 210 hysteresis = <2000>; 204 hysteresis = <2000>; 211 type = "active"; 205 type = "active"; 212 }; 206 }; 213 207 214 cpu_hot: cpu_hot { 208 cpu_hot: cpu_hot { 215 temperature = <65000>; 209 temperature = <65000>; 216 hysteresis = <2000>; 210 hysteresis = <2000>; 217 type = "active"; 211 type = "active"; 218 }; 212 }; 219 }; 213 }; 220 214 221 cooling-maps { 215 cooling-maps { 222 map2 { 216 map2 { 223 trip = <&cpu_warm>; 217 trip = <&cpu_warm>; 224 cooling-device = <&fan 218 cooling-device = <&fan THERMAL_NO_LIMIT 1>; 225 }; 219 }; 226 220 227 map3 { 221 map3 { 228 trip = <&cpu_hot>; 222 trip = <&cpu_hot>; 229 cooling-device = <&fan 223 cooling-device = <&fan 2 THERMAL_NO_LIMIT>; 230 }; 224 }; 231 }; 225 }; 232 }; 226 }; 233 227 234 &emmc_phy { 228 &emmc_phy { 235 status = "okay"; 229 status = "okay"; 236 }; 230 }; 237 231 238 &gmac { 232 &gmac { 239 assigned-clocks = <&cru SCLK_RMII_SRC> 233 assigned-clocks = <&cru SCLK_RMII_SRC>; 240 assigned-clock-parents = <&clkin_gmac> 234 assigned-clock-parents = <&clkin_gmac>; 241 clock_in_out = "input"; 235 clock_in_out = "input"; 242 phy-supply = <&vcc_lan>; 236 phy-supply = <&vcc_lan>; 243 phy-mode = "rgmii"; 237 phy-mode = "rgmii"; 244 pinctrl-names = "default"; 238 pinctrl-names = "default"; 245 pinctrl-0 = <&rgmii_pins>; 239 pinctrl-0 = <&rgmii_pins>; 246 snps,reset-gpio = <&gpio3 RK_PB7 GPIO_ 240 snps,reset-gpio = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>; 247 snps,reset-active-low; 241 snps,reset-active-low; 248 snps,reset-delays-us = <0 10000 50000> 242 snps,reset-delays-us = <0 10000 50000>; 249 tx_delay = <0x28>; 243 tx_delay = <0x28>; 250 rx_delay = <0x11>; 244 rx_delay = <0x11>; 251 }; 245 }; 252 246 253 &gpu { 247 &gpu { 254 mali-supply = <&vdd_gpu>; 248 mali-supply = <&vdd_gpu>; 255 status = "okay"; 249 status = "okay"; 256 }; 250 }; 257 251 258 &gpu_thermal { 252 &gpu_thermal { 259 trips { 253 trips { 260 gpu_warm: gpu_warm { 254 gpu_warm: gpu_warm { 261 temperature = <55000>; 255 temperature = <55000>; 262 hysteresis = <2000>; 256 hysteresis = <2000>; 263 type = "active"; 257 type = "active"; 264 }; 258 }; 265 259 266 gpu_hot: gpu_hot { 260 gpu_hot: gpu_hot { 267 temperature = <65000>; 261 temperature = <65000>; 268 hysteresis = <2000>; 262 hysteresis = <2000>; 269 type = "active"; 263 type = "active"; 270 }; 264 }; 271 }; 265 }; 272 266 273 cooling-maps { 267 cooling-maps { 274 map1 { 268 map1 { 275 trip = <&gpu_warm>; 269 trip = <&gpu_warm>; 276 cooling-device = <&fan 270 cooling-device = <&fan THERMAL_NO_LIMIT 1>; 277 }; 271 }; 278 272 279 map2 { 273 map2 { 280 trip = <&gpu_hot>; 274 trip = <&gpu_hot>; 281 cooling-device = <&fan 275 cooling-device = <&fan 2 THERMAL_NO_LIMIT>; 282 }; 276 }; 283 }; 277 }; 284 }; 278 }; 285 279 286 &hdmi { 280 &hdmi { 287 ddc-i2c-bus = <&i2c3>; 281 ddc-i2c-bus = <&i2c3>; 288 pinctrl-names = "default"; 282 pinctrl-names = "default"; 289 pinctrl-0 = <&hdmi_cec>; 283 pinctrl-0 = <&hdmi_cec>; 290 status = "okay"; 284 status = "okay"; 291 }; 285 }; 292 286 293 &hdmi_sound { 287 &hdmi_sound { 294 status = "okay"; 288 status = "okay"; 295 }; 289 }; 296 290 297 &i2c3 { 291 &i2c3 { 298 i2c-scl-rising-time-ns = <450>; 292 i2c-scl-rising-time-ns = <450>; 299 i2c-scl-falling-time-ns = <15>; 293 i2c-scl-falling-time-ns = <15>; 300 status = "okay"; 294 status = "okay"; 301 }; 295 }; 302 296 303 &i2c4 { 297 &i2c4 { 304 clock-frequency = <400000>; 298 clock-frequency = <400000>; 305 i2c-scl-rising-time-ns = <168>; 299 i2c-scl-rising-time-ns = <168>; 306 i2c-scl-falling-time-ns = <4>; 300 i2c-scl-falling-time-ns = <4>; 307 status = "okay"; 301 status = "okay"; 308 302 309 rk808: pmic@1b { 303 rk808: pmic@1b { 310 compatible = "rockchip,rk808"; 304 compatible = "rockchip,rk808"; 311 reg = <0x1b>; 305 reg = <0x1b>; 312 interrupt-parent = <&gpio1>; 306 interrupt-parent = <&gpio1>; 313 interrupts = <RK_PC6 IRQ_TYPE_ 307 interrupts = <RK_PC6 IRQ_TYPE_LEVEL_LOW>; 314 #clock-cells = <1>; 308 #clock-cells = <1>; 315 clock-output-names = "xin32k", 309 clock-output-names = "xin32k", "rk808-clkout2"; 316 pinctrl-names = "default"; 310 pinctrl-names = "default"; 317 pinctrl-0 = <&pmic_int_l>; 311 pinctrl-0 = <&pmic_int_l>; 318 rockchip,system-power-controll 312 rockchip,system-power-controller; 319 wakeup-source; 313 wakeup-source; 320 314 321 vcc1-supply = <&vsys_3v3>; 315 vcc1-supply = <&vsys_3v3>; 322 vcc2-supply = <&vsys_3v3>; 316 vcc2-supply = <&vsys_3v3>; 323 vcc3-supply = <&vsys_3v3>; 317 vcc3-supply = <&vsys_3v3>; 324 vcc4-supply = <&vsys_3v3>; 318 vcc4-supply = <&vsys_3v3>; 325 vcc6-supply = <&vsys_3v3>; 319 vcc6-supply = <&vsys_3v3>; 326 vcc7-supply = <&vsys_3v3>; 320 vcc7-supply = <&vsys_3v3>; 327 vcc8-supply = <&vsys_3v3>; 321 vcc8-supply = <&vsys_3v3>; 328 vcc9-supply = <&vsys_3v3>; 322 vcc9-supply = <&vsys_3v3>; 329 vcc10-supply = <&vsys_3v3>; 323 vcc10-supply = <&vsys_3v3>; 330 vcc11-supply = <&vsys_3v3>; 324 vcc11-supply = <&vsys_3v3>; 331 vcc12-supply = <&vsys_3v3>; 325 vcc12-supply = <&vsys_3v3>; 332 vddio-supply = <&vcc_1v8>; 326 vddio-supply = <&vcc_1v8>; 333 327 334 regulators { 328 regulators { 335 vdd_center: DCDC_REG1 329 vdd_center: DCDC_REG1 { 336 regulator-name 330 regulator-name = "vdd_center"; 337 regulator-alwa 331 regulator-always-on; 338 regulator-boot 332 regulator-boot-on; 339 regulator-min- 333 regulator-min-microvolt = <750000>; 340 regulator-max- 334 regulator-max-microvolt = <1350000>; 341 regulator-ramp 335 regulator-ramp-delay = <6001>; 342 336 343 regulator-stat 337 regulator-state-mem { 344 regula 338 regulator-off-in-suspend; 345 }; 339 }; 346 }; 340 }; 347 341 348 vdd_cpu_l: DCDC_REG2 { 342 vdd_cpu_l: DCDC_REG2 { 349 regulator-name 343 regulator-name = "vdd_cpu_l"; 350 regulator-alwa 344 regulator-always-on; 351 regulator-boot 345 regulator-boot-on; 352 regulator-min- 346 regulator-min-microvolt = <750000>; 353 regulator-max- 347 regulator-max-microvolt = <1350000>; 354 regulator-ramp 348 regulator-ramp-delay = <6001>; 355 349 356 regulator-stat 350 regulator-state-mem { 357 regula 351 regulator-off-in-suspend; 358 }; 352 }; 359 }; 353 }; 360 354 361 vcc_ddr: DCDC_REG3 { 355 vcc_ddr: DCDC_REG3 { 362 regulator-name 356 regulator-name = "vcc_ddr"; 363 regulator-alwa 357 regulator-always-on; 364 regulator-boot 358 regulator-boot-on; 365 359 366 regulator-stat 360 regulator-state-mem { 367 regula 361 regulator-on-in-suspend; 368 }; 362 }; 369 }; 363 }; 370 364 371 vcc_1v8: DCDC_REG4 { 365 vcc_1v8: DCDC_REG4 { 372 regulator-name 366 regulator-name = "vcc_1v8"; 373 regulator-alwa 367 regulator-always-on; 374 regulator-boot 368 regulator-boot-on; 375 regulator-min- 369 regulator-min-microvolt = <1800000>; 376 regulator-max- 370 regulator-max-microvolt = <1800000>; 377 371 378 regulator-stat 372 regulator-state-mem { 379 regula 373 regulator-on-in-suspend; 380 regula 374 regulator-suspend-microvolt = <1800000>; 381 }; 375 }; 382 }; 376 }; 383 377 384 vcc1v8_apio2: LDO_REG1 378 vcc1v8_apio2: LDO_REG1 { 385 regulator-name 379 regulator-name = "vcc1v8_apio2"; 386 regulator-alwa 380 regulator-always-on; 387 regulator-boot 381 regulator-boot-on; 388 regulator-min- 382 regulator-min-microvolt = <1800000>; 389 regulator-max- 383 regulator-max-microvolt = <1800000>; 390 384 391 regulator-stat 385 regulator-state-mem { 392 regula 386 regulator-off-in-suspend; 393 }; 387 }; 394 }; 388 }; 395 389 396 vcc_vldo2: LDO_REG2 { 390 vcc_vldo2: LDO_REG2 { 397 regulator-name 391 regulator-name = "vcc_vldo2"; 398 regulator-alwa 392 regulator-always-on; 399 regulator-boot 393 regulator-boot-on; 400 regulator-min- 394 regulator-min-microvolt = <3000000>; 401 regulator-max- 395 regulator-max-microvolt = <3000000>; 402 396 403 regulator-stat 397 regulator-state-mem { 404 regula 398 regulator-off-in-suspend; 405 }; 399 }; 406 }; 400 }; 407 401 408 vcc1v8_pmupll: LDO_REG 402 vcc1v8_pmupll: LDO_REG3 { 409 regulator-name 403 regulator-name = "vcc1v8_pmupll"; 410 regulator-alwa 404 regulator-always-on; 411 regulator-boot 405 regulator-boot-on; 412 regulator-min- 406 regulator-min-microvolt = <1800000>; 413 regulator-max- 407 regulator-max-microvolt = <1800000>; 414 408 415 regulator-stat 409 regulator-state-mem { 416 regula 410 regulator-on-in-suspend; 417 regula 411 regulator-suspend-microvolt = <1800000>; 418 }; 412 }; 419 }; 413 }; 420 414 421 vccio_sd: LDO_REG4 { 415 vccio_sd: LDO_REG4 { 422 regulator-name 416 regulator-name = "vccio_sd"; 423 regulator-alwa 417 regulator-always-on; 424 regulator-boot 418 regulator-boot-on; 425 regulator-min- 419 regulator-min-microvolt = <1800000>; 426 regulator-max- 420 regulator-max-microvolt = <3000000>; 427 421 428 regulator-stat 422 regulator-state-mem { 429 regula 423 regulator-on-in-suspend; 430 regula 424 regulator-suspend-microvolt = <3000000>; 431 }; 425 }; 432 }; 426 }; 433 427 434 vcc_vldo5: LDO_REG5 { 428 vcc_vldo5: LDO_REG5 { 435 regulator-name 429 regulator-name = "vcc_vldo5"; 436 regulator-alwa 430 regulator-always-on; 437 regulator-boot 431 regulator-boot-on; 438 regulator-min- 432 regulator-min-microvolt = <3000000>; 439 regulator-max- 433 regulator-max-microvolt = <3000000>; 440 434 441 regulator-stat 435 regulator-state-mem { 442 regula 436 regulator-off-in-suspend; 443 }; 437 }; 444 }; 438 }; 445 439 446 vcc_1v5: LDO_REG6 { 440 vcc_1v5: LDO_REG6 { 447 regulator-name 441 regulator-name = "vcc_1v5"; 448 regulator-alwa 442 regulator-always-on; 449 regulator-boot 443 regulator-boot-on; 450 regulator-min- 444 regulator-min-microvolt = <1500000>; 451 regulator-max- 445 regulator-max-microvolt = <1500000>; 452 446 453 regulator-stat 447 regulator-state-mem { 454 regula 448 regulator-on-in-suspend; 455 regula 449 regulator-suspend-microvolt = <1500000>; 456 }; 450 }; 457 }; 451 }; 458 452 459 vcc1v8_codec: LDO_REG7 453 vcc1v8_codec: LDO_REG7 { 460 regulator-name 454 regulator-name = "vcc1v8_codec"; 461 regulator-alwa 455 regulator-always-on; 462 regulator-boot 456 regulator-boot-on; 463 regulator-min- 457 regulator-min-microvolt = <1800000>; 464 regulator-max- 458 regulator-max-microvolt = <1800000>; 465 459 466 regulator-stat 460 regulator-state-mem { 467 regula 461 regulator-off-in-suspend; 468 }; 462 }; 469 }; 463 }; 470 464 471 vcc_3v0: LDO_REG8 { 465 vcc_3v0: LDO_REG8 { 472 regulator-name 466 regulator-name = "vcc_3v0"; 473 regulator-alwa 467 regulator-always-on; 474 regulator-boot 468 regulator-boot-on; 475 regulator-min- 469 regulator-min-microvolt = <3000000>; 476 regulator-max- 470 regulator-max-microvolt = <3000000>; 477 471 478 regulator-stat 472 regulator-state-mem { 479 regula 473 regulator-on-in-suspend; 480 regula 474 regulator-suspend-microvolt = <3000000>; 481 }; 475 }; 482 }; 476 }; 483 477 484 vcc3v3_s3: vcc_lan: SW 478 vcc3v3_s3: vcc_lan: SWITCH_REG1 { 485 regulator-name 479 regulator-name = "vcc3v3_s3"; 486 regulator-alwa 480 regulator-always-on; 487 regulator-boot 481 regulator-boot-on; 488 482 489 regulator-stat 483 regulator-state-mem { 490 regula 484 regulator-off-in-suspend; 491 }; 485 }; 492 }; 486 }; 493 487 494 vcc3v3_s0: SWITCH_REG2 488 vcc3v3_s0: SWITCH_REG2 { 495 regulator-name 489 regulator-name = "vcc3v3_s0"; 496 regulator-alwa 490 regulator-always-on; 497 regulator-boot 491 regulator-boot-on; 498 492 499 regulator-stat 493 regulator-state-mem { 500 regula 494 regulator-off-in-suspend; 501 }; 495 }; 502 }; 496 }; 503 }; 497 }; 504 }; 498 }; 505 499 506 vdd_cpu_b: regulator@40 { 500 vdd_cpu_b: regulator@40 { 507 compatible = "silergy,syr827"; 501 compatible = "silergy,syr827"; 508 reg = <0x40>; 502 reg = <0x40>; 509 fcs,suspend-voltage-selector = 503 fcs,suspend-voltage-selector = <1>; 510 pinctrl-names = "default"; 504 pinctrl-names = "default"; 511 pinctrl-0 = <&cpu_b_sleep>; 505 pinctrl-0 = <&cpu_b_sleep>; 512 regulator-name = "vdd_cpu_b"; 506 regulator-name = "vdd_cpu_b"; 513 regulator-min-microvolt = <712 507 regulator-min-microvolt = <712500>; 514 regulator-max-microvolt = <150 508 regulator-max-microvolt = <1500000>; 515 regulator-ramp-delay = <1000>; 509 regulator-ramp-delay = <1000>; 516 regulator-always-on; 510 regulator-always-on; 517 regulator-boot-on; 511 regulator-boot-on; 518 vin-supply = <&vsys_3v3>; 512 vin-supply = <&vsys_3v3>; 519 513 520 regulator-state-mem { 514 regulator-state-mem { 521 regulator-off-in-suspe 515 regulator-off-in-suspend; 522 }; 516 }; 523 }; 517 }; 524 518 525 vdd_gpu: regulator@41 { 519 vdd_gpu: regulator@41 { 526 compatible = "silergy,syr828"; 520 compatible = "silergy,syr828"; 527 reg = <0x41>; 521 reg = <0x41>; 528 fcs,suspend-voltage-selector = 522 fcs,suspend-voltage-selector = <1>; 529 pinctrl-names = "default"; 523 pinctrl-names = "default"; 530 pinctrl-0 = <&gpu_sleep>; 524 pinctrl-0 = <&gpu_sleep>; 531 regulator-name = "vdd_gpu"; 525 regulator-name = "vdd_gpu"; 532 regulator-min-microvolt = <712 526 regulator-min-microvolt = <712500>; 533 regulator-max-microvolt = <150 527 regulator-max-microvolt = <1500000>; 534 regulator-ramp-delay = <1000>; 528 regulator-ramp-delay = <1000>; 535 regulator-always-on; 529 regulator-always-on; 536 regulator-boot-on; 530 regulator-boot-on; 537 vin-supply = <&vsys_3v3>; 531 vin-supply = <&vsys_3v3>; 538 532 539 regulator-state-mem { 533 regulator-state-mem { 540 regulator-off-in-suspe 534 regulator-off-in-suspend; 541 }; 535 }; 542 }; 536 }; 543 }; 537 }; 544 538 545 &i2c8 { 539 &i2c8 { 546 clock-frequency = <400000>; 540 clock-frequency = <400000>; 547 i2c-scl-rising-time-ns = <160>; 541 i2c-scl-rising-time-ns = <160>; 548 i2c-scl-falling-time-ns = <30>; 542 i2c-scl-falling-time-ns = <30>; 549 status = "okay"; 543 status = "okay"; 550 }; 544 }; 551 545 552 &i2s0 { 546 &i2s0 { 553 rockchip,playback-channels = <8>; 547 rockchip,playback-channels = <8>; 554 rockchip,capture-channels = <8>; 548 rockchip,capture-channels = <8>; 555 status = "okay"; 549 status = "okay"; 556 }; 550 }; 557 551 558 &i2s1 { 552 &i2s1 { 559 rockchip,playback-channels = <2>; 553 rockchip,playback-channels = <2>; 560 rockchip,capture-channels = <2>; 554 rockchip,capture-channels = <2>; 561 status = "okay"; 555 status = "okay"; 562 }; 556 }; 563 557 564 &i2s2 { 558 &i2s2 { 565 status = "okay"; 559 status = "okay"; 566 }; 560 }; 567 561 568 &io_domains { 562 &io_domains { 569 bt656-supply = <&vcc1v8_apio2>; 563 bt656-supply = <&vcc1v8_apio2>; 570 audio-supply = <&vcc1v8_codec>; 564 audio-supply = <&vcc1v8_codec>; 571 sdmmc-supply = <&vccio_sd>; 565 sdmmc-supply = <&vccio_sd>; 572 gpio1830-supply = <&vcc_3v0>; 566 gpio1830-supply = <&vcc_3v0>; 573 status = "okay"; 567 status = "okay"; 574 }; 568 }; 575 569 576 &pmu_io_domains { 570 &pmu_io_domains { 577 pmu1830-supply = <&vcc_1v8>; 571 pmu1830-supply = <&vcc_1v8>; 578 status = "okay"; 572 status = "okay"; 579 }; 573 }; 580 574 581 &pinctrl { 575 &pinctrl { 582 bt { 576 bt { 583 bt_host_wake_l: bt-host-wake-l 577 bt_host_wake_l: bt-host-wake-l { 584 rockchip,pins = <0 RK_ 578 rockchip,pins = <0 RK_PA4 RK_FUNC_GPIO &pcfg_pull_none>; 585 }; 579 }; 586 580 587 bt_reg_on_h: bt-reg-on-h { 581 bt_reg_on_h: bt-reg-on-h { 588 rockchip,pins = <2 RK_ 582 rockchip,pins = <2 RK_PD3 RK_FUNC_GPIO &pcfg_pull_none>; 589 }; 583 }; 590 584 591 bt_wake_l: bt-wake-l { 585 bt_wake_l: bt-wake-l { 592 rockchip,pins = <2 RK_ 586 rockchip,pins = <2 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>; 593 }; 587 }; 594 }; 588 }; 595 589 596 buttons { 590 buttons { 597 pwrbtn: pwrbtn { 591 pwrbtn: pwrbtn { 598 rockchip,pins = <0 RK_ 592 rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_up>; 599 }; 593 }; 600 }; 594 }; 601 595 602 ir { 596 ir { 603 ir_rx: ir-rx { 597 ir_rx: ir-rx { 604 rockchip,pins = <1 RK_PB6 598 rockchip,pins = <1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_none>; 605 }; 599 }; 606 }; 600 }; 607 601 608 leds { 602 leds { 609 sys_led_pin: sys-led-pin { 603 sys_led_pin: sys-led-pin { 610 rockchip,pins = <0 RK_ 604 rockchip,pins = <0 RK_PA6 RK_FUNC_GPIO &pcfg_pull_none>; 611 }; 605 }; 612 606 613 user_led_pin: user-led-pin { 607 user_led_pin: user-led-pin { 614 rockchip,pins = <4 RK_ 608 rockchip,pins = <4 RK_PD0 RK_FUNC_GPIO &pcfg_pull_none>; 615 }; 609 }; 616 }; 610 }; 617 611 618 pmic { 612 pmic { 619 pmic_int_l: pmic-int-l { 613 pmic_int_l: pmic-int-l { 620 rockchip,pins = <1 RK_ 614 rockchip,pins = <1 RK_PC6 RK_FUNC_GPIO &pcfg_pull_up>; 621 }; 615 }; 622 616 623 cpu_b_sleep: cpu-b-sleep { 617 cpu_b_sleep: cpu-b-sleep { 624 rockchip,pins = <1 RK_ 618 rockchip,pins = <1 RK_PB5 RK_FUNC_GPIO &pcfg_pull_down>; 625 }; 619 }; 626 620 627 gpu_sleep: gpu-sleep { 621 gpu_sleep: gpu-sleep { 628 rockchip,pins = <0 RK_ 622 rockchip,pins = <0 RK_PB5 RK_FUNC_GPIO &pcfg_pull_down>; 629 }; 623 }; 630 }; 624 }; 631 625 632 sdio-pwrseq { 626 sdio-pwrseq { 633 wifi_enable_h: wifi-enable-h { 627 wifi_enable_h: wifi-enable-h { 634 rockchip,pins = <2 RK_ 628 rockchip,pins = <2 RK_PD4 RK_FUNC_GPIO &pcfg_pull_none>; 635 }; 629 }; 636 }; 630 }; 637 631 638 usb2 { 632 usb2 { 639 vcc5v0_host_en: vcc5v0-host-en 633 vcc5v0_host_en: vcc5v0-host-en { 640 rockchip,pins = <4 RK_ 634 rockchip,pins = <4 RK_PD1 RK_FUNC_GPIO &pcfg_pull_none>; 641 }; 635 }; 642 }; 636 }; 643 637 644 wifi { 638 wifi { 645 wifi_host_wake_l: wifi-host-wa 639 wifi_host_wake_l: wifi-host-wake-l { 646 rockchip,pins = <0 RK_ 640 rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>; 647 }; 641 }; 648 }; 642 }; 649 }; 643 }; 650 644 651 &pwm0 { 645 &pwm0 { 652 status = "okay"; 646 status = "okay"; 653 }; 647 }; 654 648 655 &pwm2 { 649 &pwm2 { 656 status = "okay"; 650 status = "okay"; 657 }; 651 }; 658 652 659 &saradc { 653 &saradc { 660 vref-supply = <&vcca1v8_s3>; 654 vref-supply = <&vcca1v8_s3>; 661 status = "okay"; 655 status = "okay"; 662 }; 656 }; 663 657 664 &sdio0 { 658 &sdio0 { 665 /* WiFi & BT combo module Ampak AP6356 659 /* WiFi & BT combo module Ampak AP6356S */ 666 bus-width = <4>; 660 bus-width = <4>; 667 cap-sdio-irq; 661 cap-sdio-irq; 668 cap-sd-highspeed; 662 cap-sd-highspeed; 669 keep-power-in-suspend; 663 keep-power-in-suspend; 670 mmc-pwrseq = <&sdio_pwrseq>; 664 mmc-pwrseq = <&sdio_pwrseq>; 671 non-removable; 665 non-removable; 672 pinctrl-names = "default"; 666 pinctrl-names = "default"; 673 pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &s 667 pinctrl-0 = <&sdio0_bus4 &sdio0_cmd &sdio0_clk>; 674 sd-uhs-sdr104; 668 sd-uhs-sdr104; 675 vqmmc-supply = <&vcc1v8_s3>; 669 vqmmc-supply = <&vcc1v8_s3>; 676 vmmc-supply = <&vccio_sd>; 670 vmmc-supply = <&vccio_sd>; 677 #address-cells = <1>; 671 #address-cells = <1>; 678 #size-cells = <0>; 672 #size-cells = <0>; 679 status = "okay"; 673 status = "okay"; 680 674 681 brcmf: wifi@1 { 675 brcmf: wifi@1 { 682 reg = <1>; 676 reg = <1>; 683 compatible = "brcm,bcm4329-fma 677 compatible = "brcm,bcm4329-fmac"; 684 interrupt-parent = <&gpio0>; 678 interrupt-parent = <&gpio0>; 685 interrupts = <RK_PA3 IRQ_TYPE_ !! 679 interrupts = <RK_PA3 GPIO_ACTIVE_HIGH>; 686 interrupt-names = "host-wake"; 680 interrupt-names = "host-wake"; 687 brcm,drive-strength = <5>; 681 brcm,drive-strength = <5>; 688 pinctrl-names = "default"; 682 pinctrl-names = "default"; 689 pinctrl-0 = <&wifi_host_wake_l 683 pinctrl-0 = <&wifi_host_wake_l>; 690 }; 684 }; 691 }; 685 }; 692 686 693 &sdmmc { 687 &sdmmc { 694 bus-width = <4>; 688 bus-width = <4>; 695 cap-mmc-highspeed; 689 cap-mmc-highspeed; 696 cap-sd-highspeed; 690 cap-sd-highspeed; 697 cd-gpios = <&gpio0 RK_PA7 GPIO_ACTIVE_ 691 cd-gpios = <&gpio0 RK_PA7 GPIO_ACTIVE_LOW>; 698 disable-wp; 692 disable-wp; 699 max-frequency = <150000000>; 693 max-frequency = <150000000>; 700 pinctrl-names = "default"; 694 pinctrl-names = "default"; 701 pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sd 695 pinctrl-0 = <&sdmmc_clk &sdmmc_cmd &sdmmc_bus4>; 702 status = "okay"; 696 status = "okay"; 703 }; 697 }; 704 698 705 &sdhci { 699 &sdhci { 706 bus-width = <8>; 700 bus-width = <8>; 707 mmc-hs400-1_8v; 701 mmc-hs400-1_8v; 708 non-removable; 702 non-removable; 709 status = "okay"; 703 status = "okay"; 710 }; 704 }; 711 705 712 &spi1 { 706 &spi1 { 713 status = "okay"; 707 status = "okay"; 714 708 715 spiflash: flash@0 { 709 spiflash: flash@0 { 716 compatible = "winbond,w25q128f 710 compatible = "winbond,w25q128fw", "jedec,spi-nor"; 717 reg = <0>; 711 reg = <0>; 718 spi-max-frequency = <104000000 712 spi-max-frequency = <104000000>; 719 }; 713 }; 720 }; 714 }; 721 715 722 &tcphy0 { 716 &tcphy0 { 723 status = "okay"; 717 status = "okay"; 724 }; 718 }; 725 719 726 &tcphy1 { 720 &tcphy1 { 727 status = "okay"; 721 status = "okay"; 728 }; 722 }; 729 723 730 &tsadc { 724 &tsadc { 731 /* tshut mode 0:CRU 1:GPIO */ 725 /* tshut mode 0:CRU 1:GPIO */ 732 rockchip,hw-tshut-mode = <1>; 726 rockchip,hw-tshut-mode = <1>; 733 /* tshut polarity 0:LOW 1:HIGH */ 727 /* tshut polarity 0:LOW 1:HIGH */ 734 rockchip,hw-tshut-polarity = <1>; 728 rockchip,hw-tshut-polarity = <1>; 735 status = "okay"; 729 status = "okay"; 736 }; 730 }; 737 731 738 &u2phy0 { 732 &u2phy0 { 739 status = "okay"; 733 status = "okay"; 740 734 741 u2phy0_otg: otg-port { 735 u2phy0_otg: otg-port { 742 status = "okay"; 736 status = "okay"; 743 }; 737 }; 744 738 745 u2phy0_host: host-port { 739 u2phy0_host: host-port { 746 phy-supply = <&vcc5v0_host>; 740 phy-supply = <&vcc5v0_host>; 747 status = "okay"; 741 status = "okay"; 748 }; 742 }; 749 }; 743 }; 750 744 751 &u2phy1 { 745 &u2phy1 { 752 status = "okay"; 746 status = "okay"; 753 747 754 u2phy1_otg: otg-port { 748 u2phy1_otg: otg-port { 755 status = "okay"; 749 status = "okay"; 756 }; 750 }; 757 751 758 u2phy1_host: host-port { 752 u2phy1_host: host-port { 759 phy-supply = <&vcc5v0_host>; 753 phy-supply = <&vcc5v0_host>; 760 status = "okay"; 754 status = "okay"; 761 }; 755 }; 762 }; 756 }; 763 757 764 &uart0 { 758 &uart0 { 765 pinctrl-names = "default"; 759 pinctrl-names = "default"; 766 pinctrl-0 = <&uart0_xfer &uart0_rts &u 760 pinctrl-0 = <&uart0_xfer &uart0_rts &uart0_cts>; 767 status = "okay"; 761 status = "okay"; 768 762 769 bluetooth { 763 bluetooth { 770 compatible = "brcm,bcm43438-bt 764 compatible = "brcm,bcm43438-bt"; 771 clocks = <&rk808 1>; 765 clocks = <&rk808 1>; 772 clock-names = "lpo"; 766 clock-names = "lpo"; 773 device-wakeup-gpios = <&gpio2 767 device-wakeup-gpios = <&gpio2 RK_PD2 GPIO_ACTIVE_HIGH>; 774 host-wakeup-gpios = <&gpio0 RK 768 host-wakeup-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>; 775 shutdown-gpios = <&gpio2 RK_PD 769 shutdown-gpios = <&gpio2 RK_PD3 GPIO_ACTIVE_HIGH>; 776 max-speed = <4000000>; 770 max-speed = <4000000>; 777 pinctrl-names = "default"; 771 pinctrl-names = "default"; 778 pinctrl-0 = <&bt_reg_on_h &bt_ 772 pinctrl-0 = <&bt_reg_on_h &bt_host_wake_l &bt_wake_l>; 779 vbat-supply = <&vsys_3v3>; 773 vbat-supply = <&vsys_3v3>; 780 vddio-supply = <&vcc_1v8>; 774 vddio-supply = <&vcc_1v8>; 781 }; 775 }; 782 }; 776 }; 783 777 784 &uart2 { 778 &uart2 { 785 status = "okay"; 779 status = "okay"; 786 }; 780 }; 787 781 788 &usb_host0_ehci { 782 &usb_host0_ehci { 789 status = "okay"; 783 status = "okay"; 790 }; 784 }; 791 785 792 &usb_host0_ohci { 786 &usb_host0_ohci { 793 status = "okay"; 787 status = "okay"; 794 }; 788 }; 795 789 796 &usb_host1_ehci { 790 &usb_host1_ehci { 797 status = "okay"; 791 status = "okay"; 798 }; 792 }; 799 793 800 &usb_host1_ohci { 794 &usb_host1_ohci { 801 status = "okay"; 795 status = "okay"; 802 }; 796 }; 803 797 804 &usbdrd3_0 { 798 &usbdrd3_0 { 805 status = "okay"; 799 status = "okay"; 806 }; 800 }; 807 801 808 &usbdrd_dwc3_0 { 802 &usbdrd_dwc3_0 { 809 status = "okay"; 803 status = "okay"; 810 dr_mode = "otg"; 804 dr_mode = "otg"; 811 }; 805 }; 812 806 813 &usbdrd3_1 { 807 &usbdrd3_1 { 814 status = "okay"; 808 status = "okay"; 815 }; 809 }; 816 810 817 &usbdrd_dwc3_1 { 811 &usbdrd_dwc3_1 { 818 status = "okay"; 812 status = "okay"; 819 dr_mode = "host"; 813 dr_mode = "host"; 820 }; 814 }; 821 815 822 &vopb { 816 &vopb { 823 status = "okay"; 817 status = "okay"; 824 }; 818 }; 825 819 826 &vopb_mmu { 820 &vopb_mmu { 827 status = "okay"; 821 status = "okay"; 828 }; 822 }; 829 823 830 &vopl { 824 &vopl { 831 status = "okay"; 825 status = "okay"; 832 }; 826 }; 833 827 834 &vopl_mmu { 828 &vopl_mmu { 835 status = "okay"; 829 status = "okay"; 836 }; 830 };
Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.