1// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2/* 3 * Copyright (c) 2018 Fuzhou Rockchip Electronics Co., Ltd 4 */ 5 6/dts-v1/; 7 8#include <dt-bindings/input/input.h> 9#include "rk3308.dtsi" 10 11/ { 12 model = "Rockchip RK3308 voice assistant v10 board"; 13 compatible = "rockchip,rk3308-ai-va-v10", "rockchip,rk3308"; 14 15 chosen { 16 bootargs = "earlycon=uart8250,mmio32,0xff0c0000 console=ttyFIQ0 root=PARTUUID=614e0000-0000 rootfstype=squashfs rootwait snd_aloop.index=7 snd_aloop.use_raw_jiffies=1"; 17 }; 18 19 adc-keys0 { 20 compatible = "adc-keys"; 21 io-channels = <&saradc 0>; 22 io-channel-names = "buttons"; 23 poll-interval = <100>; 24 keyup-threshold-microvolt = <1800000>; 25 26 func-key { 27 linux,code = <KEY_FN>; 28 label = "function"; 29 press-threshold-microvolt = <17000>; 30 }; 31 }; 32 33 adc-keys1 { 34 compatible = "adc-keys"; 35 io-channels = <&saradc 1>; 36 io-channel-names = "buttons"; 37 poll-interval = <100>; 38 keyup-threshold-microvolt = <1800000>; 39 40 play-key { 41 linux,code = <KEY_PLAY>; 42 label = "play"; 43 press-threshold-microvolt = <625000>; 44 }; 45 }; 46 47 gpio-keys { 48 compatible = "gpio-keys"; 49 50 pinctrl-names = "default"; 51 pinctrl-0 = <&mic_mute>; 52 53 mute { 54 gpios = <&gpio0 RK_PC0 GPIO_ACTIVE_LOW>; 55 linux,code = <KEY_MICMUTE>; 56 label = "GPIO Mic Mute"; 57 debounce-interval = <100>; 58 }; 59 }; 60 61 rotary { 62 compatible = "rotary-encoder"; 63 pinctrl-names = "default"; 64 pinctrl-0 = <&rotary_gpio>; 65 gpios = <&gpio2 RK_PB3 GPIO_ACTIVE_LOW>, 66 <&gpio2 RK_PB4 GPIO_ACTIVE_LOW>; 67 linux,axis = <0>; /* REL_X */ 68 rotary-encoder,relative-axis; 69 }; 70 71 sdio_pwrseq: sdio-pwrseq { 72 compatible = "mmc-pwrseq-simple"; 73 pinctrl-names = "default"; 74 pinctrl-0 = <&wifi_enable_h>; 75 76 /* 77 * On the module itself this is one of these (depending 78 * on the actual card populated): 79 * - SDIO_RESET_L_WL_REG_ON 80 * - PDN (power down when low) 81 */ 82 reset-gpios = <&gpio0 RK_PA2 GPIO_ACTIVE_LOW>; 83 }; 84 85 sound { 86 compatible = "simple-audio-card"; 87 simple-audio-card,format = "i2s"; 88 simple-audio-card,mclk-fs = <256>; 89 simple-audio-card,name = "i2s_8ch_0"; 90 91 simple-audio-card,dai-link@0 { 92 format = "i2s"; 93 cpu { 94 sound-dai = <&i2s_8ch_0>; 95 }; 96 97 codec { 98 sound-dai = <&dummy_codec>; 99 }; 100 }; 101 102 simple-audio-card,dai-link@1 { 103 format = "i2s"; 104 cpu { 105 sound-dai = <&i2s_8ch_0>; 106 }; 107 108 codec { 109 sound-dai = <&tas5711>; 110 }; 111 }; 112 }; 113 114 dummy_codec: dummy-codec { 115 compatible = "rockchip,dummy-codec"; 116 #sound-dai-cells = <0>; 117 }; 118 119 vdd_log: vdd_core: vdd-core { 120 compatible = "pwm-regulator"; 121 pwms = <&pwm0 0 5000 1>; 122 regulator-name = "vdd_core"; 123 regulator-min-microvolt = <827000>; 124 regulator-max-microvolt = <1340000>; 125 regulator-init-microvolt = <1015000>; 126 regulator-always-on; 127 regulator-boot-on; 128 regulator-settling-time-up-us = <250>; 129 status = "okay"; 130 }; 131 132 vdd_1v0: vdd-1v0 { 133 compatible = "regulator-fixed"; 134 regulator-name = "vdd_1v0"; 135 regulator-always-on; 136 regulator-boot-on; 137 regulator-min-microvolt = <1000000>; 138 regulator-max-microvolt = <1000000>; 139 }; 140 141 vccio_sdio: vcc_1v8: vcc-1v8 { 142 compatible = "regulator-fixed"; 143 regulator-name = "vcc_1v8"; 144 regulator-always-on; 145 regulator-boot-on; 146 regulator-min-microvolt = <1800000>; 147 regulator-max-microvolt = <1800000>; 148 vin-supply = <&vcc_io>; 149 }; 150 151 vcc_1v8_codec: vcc-1v8-codec { 152 compatible = "regulator-fixed"; 153 regulator-name = "vcc_1v8_codec"; 154 regulator-always-on; 155 regulator-boot-on; 156 regulator-min-microvolt = <1800000>; 157 regulator-max-microvolt = <1800000>; 158 vin-supply = <&vcc_io>; 159 }; 160 161 vcc_ddr: vcc-ddr { 162 compatible = "regulator-fixed"; 163 regulator-name = "vcc_ddr"; 164 regulator-always-on; 165 regulator-boot-on; 166 regulator-min-microvolt = <1500000>; 167 regulator-max-microvolt = <1500000>; 168 }; 169 170 vcc_3v3_codec: vcc_io: vcc-io { 171 compatible = "regulator-fixed"; 172 regulator-name = "vcc_io"; 173 regulator-always-on; 174 regulator-boot-on; 175 regulator-min-microvolt = <3300000>; 176 regulator-max-microvolt = <3300000>; 177 }; 178 179 vccio_flash: vccio-flash { 180 compatible = "regulator-fixed"; 181 regulator-name = "vccio_flash"; 182 regulator-always-on; 183 regulator-boot-on; 184 regulator-min-microvolt = <1800000>; 185 regulator-max-microvolt = <1800000>; 186 }; 187 188 wireless-bluetooth { 189 compatible = "bluetooth-platdata"; 190 uart_rts_gpios = <&gpio4 RK_PA7 GPIO_ACTIVE_LOW>; 191 pinctrl-names = "default", "rts_gpio"; 192 pinctrl-0 = <&uart4_rts>; 193 pinctrl-1 = <&uart4_rts_pin>; 194 BT,power_gpio = <&gpio4 RK_PB3 GPIO_ACTIVE_HIGH>; 195 BT,wake_host_irq = <&gpio4 RK_PB4 GPIO_ACTIVE_HIGH>; 196 status = "okay"; 197 }; 198 199 wireless-wlan { 200 compatible = "wlan-platdata"; 201 rockchip,grf = <&grf>; 202 pinctrl-names = "default"; 203 pinctrl-0 = <&wifi_wake_host>, <&rtc_32k>; 204 wifi_chip_type = "ap6255"; 205 WIFI,host_wake_irq = <&gpio0 RK_PA0 GPIO_ACTIVE_HIGH>; 206 status = "okay"; 207 }; 208}; 209 210&cpu0 { 211 cpu-supply = <&vdd_core>; 212}; 213 214&dmc { 215 center-supply = <&vdd_core>; 216 status = "okay"; 217}; 218 219&emmc { 220 bus-width = <8>; 221 cap-mmc-highspeed; 222 mmc-hs200-1_8v; 223 no-sdio; 224 no-sd; 225 disable-wp; 226 non-removable; 227 num-slots = <1>; 228 status = "okay"; 229}; 230 231&fiq_debugger { 232 status = "okay"; 233}; 234 235&io_domains { 236 status = "okay"; 237 238 vccio0-supply = <&vcc_io>; 239 vccio1-supply = <&vcc_io>; 240 vccio2-supply = <&vcc_1v8>; 241 vccio3-supply = <&vccio_flash>; 242 vccio4-supply = <&vccio_sdio>; 243 vccio5-supply = <&vcc_io>; 244}; 245 246&i2c1 { 247 clock-frequency = <400000>; 248 status = "okay"; 249 250 is31fl3236: led-controller@3c { 251 compatible = "issi,is31fl3236"; 252 reg = <0x3c>; 253 #address-cells = <1>; 254 #size-cells = <0>; 255 reset-gpios = <&gpio0 RK_PB0 GPIO_ACTIVE_HIGH>; 256 status = "okay"; 257 258 led1: led@1 { 259 label = "led1"; 260 reg = <1>; 261 led-max-microamp = <10000>; 262 linux,default-trigger = "timer"; 263 linux,default-trigger-delay-ms = <0>; 264 linux,blink-delay-on-ms = <100>; 265 linux,blink-delay-off-ms = <1200>; 266 }; 267 268 led2: led@2 { 269 label = "led2"; 270 reg = <2>; 271 led-max-microamp = <10000>; 272 linux,default-trigger = "timer"; 273 linux,default-trigger-delay-ms = <0>; 274 linux,blink-delay-on-ms = <100>; 275 linux,blink-delay-off-ms = <1200>; 276 }; 277 278 led3: led@3 { 279 label = "led3"; 280 reg = <3>; 281 led-max-microamp = <10000>; 282 linux,default-trigger = "default-on"; 283 }; 284 285 led4: led@4 { 286 label = "led4"; 287 reg = <4>; 288 led-max-microamp = <10000>; 289 linux,default-trigger = "timer"; 290 linux,default-trigger-delay-ms = <100>; 291 linux,blink-delay-on-ms = <100>; 292 linux,blink-delay-off-ms = <1200>; 293 }; 294 295 led5: led@5 { 296 label = "led5"; 297 reg = <5>; 298 led-max-microamp = <10000>; 299 linux,default-trigger = "timer"; 300 linux,default-trigger-delay-ms = <100>; 301 linux,blink-delay-on-ms = <100>; 302 linux,blink-delay-off-ms = <1200>; 303 }; 304 305 led6: led@6 { 306 label = "led6"; 307 reg = <6>; 308 led-max-microamp = <10000>; 309 linux,default-trigger = "default-on"; 310 }; 311 312 led7: led@7 { 313 label = "led7"; 314 reg = <7>; 315 led-max-microamp = <10000>; 316 linux,default-trigger = "timer"; 317 linux,default-trigger-delay-ms = <200>; 318 linux,blink-delay-on-ms = <100>; 319 linux,blink-delay-off-ms = <1200>; 320 }; 321 322 led8: led@8 { 323 label = "led8"; 324 reg = <8>; 325 led-max-microamp = <10000>; 326 linux,default-trigger = "timer"; 327 linux,default-trigger-delay-ms = <200>; 328 linux,blink-delay-on-ms = <100>; 329 linux,blink-delay-off-ms = <1200>; 330 }; 331 332 led9: led@9 { 333 label = "led9"; 334 reg = <9>; 335 led-max-microamp = <10000>; 336 linux,default-trigger = "default-on"; 337 }; 338 339 led10: led@10 { 340 label = "led10"; 341 reg = <10>; 342 led-max-microamp = <10000>; 343 linux,default-trigger = "timer"; 344 linux,default-trigger-delay-ms = <300>; 345 linux,blink-delay-on-ms = <100>; 346 linux,blink-delay-off-ms = <1200>; 347 }; 348 349 led11: led@11 { 350 label = "led11"; 351 reg = <11>; 352 led-max-microamp = <10000>; 353 linux,default-trigger = "timer"; 354 linux,default-trigger-delay-ms = <300>; 355 linux,blink-delay-on-ms = <100>; 356 linux,blink-delay-off-ms = <1200>; 357 }; 358 359 led12: led@12 { 360 label = "led12"; 361 reg = <12>; 362 led-max-microamp = <10000>; 363 linux,default-trigger = "default-on"; 364 }; 365 366 led13: led@13 { 367 label = "led13"; 368 reg = <13>; 369 led-max-microamp = <10000>; 370 linux,default-trigger = "timer"; 371 linux,default-trigger-delay-ms = <400>; 372 linux,blink-delay-on-ms = <100>; 373 linux,blink-delay-off-ms = <1200>; 374 }; 375 376 led14: led@14 { 377 label = "led14"; 378 reg = <14>; 379 led-max-microamp = <10000>; 380 linux,default-trigger = "timer"; 381 linux,default-trigger-delay-ms = <400>; 382 linux,blink-delay-on-ms = <100>; 383 linux,blink-delay-off-ms = <1200>; 384 }; 385 386 led15: led@15 { 387 label = "led15"; 388 reg = <15>; 389 led-max-microamp = <10000>; 390 linux,default-trigger = "default-on"; 391 }; 392 393 led16: led@16 { 394 label = "led16"; 395 reg = <16>; 396 led-max-microamp = <10000>; 397 linux,default-trigger = "timer"; 398 linux,default-trigger-delay-ms = <500>; 399 linux,blink-delay-on-ms = <100>; 400 linux,blink-delay-off-ms = <1200>; 401 }; 402 403 led17: led@17 { 404 label = "led17"; 405 reg = <17>; 406 led-max-microamp = <10000>; 407 linux,default-trigger = "timer"; 408 linux,default-trigger-delay-ms = <500>; 409 linux,blink-delay-on-ms = <100>; 410 linux,blink-delay-off-ms = <1200>; 411 }; 412 413 led18: led@18 { 414 label = "led18"; 415 reg = <18>; 416 led-max-microamp = <10000>; 417 linux,default-trigger = "default-on"; 418 }; 419 420 led19: led@19 { 421 label = "led19"; 422 reg = <19>; 423 led-max-microamp = <10000>; 424 linux,default-trigger = "timer"; 425 linux,default-trigger-delay-ms = <600>; 426 linux,blink-delay-on-ms = <100>; 427 linux,blink-delay-off-ms = <1200>; 428 }; 429 430 led20: led@20 { 431 label = "led20"; 432 reg = <20>; 433 led-max-microamp = <10000>; 434 linux,default-trigger = "timer"; 435 linux,default-trigger-delay-ms = <600>; 436 linux,blink-delay-on-ms = <100>; 437 linux,blink-delay-off-ms = <1200>; 438 }; 439 440 led21: led@21 { 441 label = "led21"; 442 reg = <21>; 443 led-max-microamp = <10000>; 444 linux,default-trigger = "default-on"; 445 }; 446 447 led22: led@22 { 448 label = "led22"; 449 reg = <22>; 450 led-max-microamp = <10000>; 451 linux,default-trigger = "timer"; 452 linux,default-trigger-delay-ms = <700>; 453 linux,blink-delay-on-ms = <100>; 454 linux,blink-delay-off-ms = <1200>; 455 }; 456 457 led23: led@23 { 458 label = "led23"; 459 reg = <23>; 460 led-max-microamp = <10000>; 461 linux,default-trigger = "timer"; 462 linux,default-trigger-delay-ms = <700>; 463 linux,blink-delay-on-ms = <100>; 464 linux,blink-delay-off-ms = <1200>; 465 }; 466 467 led124: led@24 { 468 label = "led24"; 469 reg = <24>; 470 led-max-microamp = <10000>; 471 linux,default-trigger = "default-on"; 472 }; 473 474 led25: led@25 { 475 label = "led25"; 476 reg = <25>; 477 led-max-microamp = <10000>; 478 linux,default-trigger = "timer"; 479 linux,default-trigger-delay-ms = <800>; 480 linux,blink-delay-on-ms = <100>; 481 linux,blink-delay-off-ms = <1200>; 482 }; 483 484 led26: led@26 { 485 label = "led26"; 486 reg = <26>; 487 led-max-microamp = <10000>; 488 linux,default-trigger = "timer"; 489 linux,default-trigger-delay-ms = <800>; 490 linux,blink-delay-on-ms = <100>; 491 linux,blink-delay-off-ms = <1200>; 492 }; 493 494 led27: led@27 { 495 label = "led27"; 496 reg = <27>; 497 led-max-microamp = <10000>; 498 linux,default-trigger = "default-on"; 499 }; 500 501 led28: led@28 { 502 label = "led28"; 503 reg = <28>; 504 led-max-microamp = <10000>; 505 linux,default-trigger = "timer"; 506 linux,default-trigger-delay-ms = <900>; 507 linux,blink-delay-on-ms = <100>; 508 linux,blink-delay-off-ms = <1200>; 509 }; 510 511 led29: led@29 { 512 label = "led29"; 513 reg = <29>; 514 led-max-microamp = <10000>; 515 linux,default-trigger = "timer"; 516 linux,default-trigger-delay-ms = <900>; 517 linux,blink-delay-on-ms = <100>; 518 linux,blink-delay-off-ms = <1200>; 519 }; 520 521 led30: led@30 { 522 label = "led30"; 523 reg = <30>; 524 led-max-microamp = <10000>; 525 linux,default-trigger = "default-on"; 526 }; 527 528 led31: led@31 { 529 label = "led31"; 530 reg = <31>; 531 led-max-microamp = <10000>; 532 linux,default-trigger = "timer"; 533 linux,default-trigger-delay-ms = <1000>; 534 linux,blink-delay-on-ms = <100>; 535 linux,blink-delay-off-ms = <1200>; 536 }; 537 538 led32: led@32 { 539 label = "led32"; 540 reg = <32>; 541 led-max-microamp = <10000>; 542 linux,default-trigger = "timer"; 543 linux,default-trigger-delay-ms = <1000>; 544 linux,blink-delay-on-ms = <100>; 545 linux,blink-delay-off-ms = <1200>; 546 }; 547 548 led33: led@33 { 549 label = "led33"; 550 reg = <33>; 551 led-max-microamp = <10000>; 552 linux,default-trigger = "default-on"; 553 }; 554 555 led34: led@34 { 556 label = "led34"; 557 reg = <34>; 558 led-max-microamp = <10000>; 559 linux,default-trigger = "timer"; 560 linux,default-trigger-delay-ms = <1100>; 561 linux,blink-delay-on-ms = <100>; 562 linux,blink-delay-off-ms = <1200>; 563 }; 564 565 led35: led@35 { 566 label = "led35"; 567 reg = <35>; 568 led-max-microamp = <10000>; 569 linux,default-trigger = "timer"; 570 linux,default-trigger-delay-ms = <1100>; 571 linux,blink-delay-on-ms = <100>; 572 linux,blink-delay-off-ms = <1200>; 573 }; 574 575 led36: led@36 { 576 label = "led36"; 577 reg = <36>; 578 led-max-microamp = <10000>; 579 linux,default-trigger = "default-on"; 580 }; 581 }; 582 583 tas5711: tas5711@1b { 584 #sound-dai-cells = <0>; 585 compatible = "ti,tas5711"; 586 reg = <0x1b>; 587 clocks = <&cru SCLK_I2S0_8CH_TX_OUT>; 588 clock-names = "mclk"; 589 pinctrl-names = "default"; 590 pinctrl-0 = <&i2s_8ch_0_mclk>; 591 pdn-gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_LOW>; 592 reset-gpios = <&gpio0 RK_PC4 GPIO_ACTIVE_LOW>; 593 }; 594}; 595 596&i2s_8ch_0 { 597 status = "okay"; 598 assigned-clocks = <&cru SCLK_I2S0_8CH_RX>; 599 assigned-clock-parents = <&cru SCLK_I2S0_8CH_TX_MUX>; 600 rockchip,clk-trcm = <1>; 601 #sound-dai-cells = <0>; 602}; 603 604&pinctrl { 605 buttons { 606 mic_mute: mic-mute { 607 rockchip,pins = <0 RK_PC0 RK_FUNC_GPIO &pcfg_pull_up>; 608 }; 609 }; 610 rotary { 611 rotary_gpio: rotary-gpio { 612 rockchip,pins = 613 <2 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>, 614 <2 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>; 615 }; 616 }; 617 sdio-pwrseq { 618 wifi_enable_h: wifi-enable-h { 619 rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_pull_none>; 620 }; 621 }; 622 623 wireless-wlan { 624 wifi_wake_host: wifi-wake-host { 625 rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_up>; 626 }; 627 }; 628}; 629 630&pwm0 { 631 status = "okay"; 632 pinctrl-names = "active"; 633 pinctrl-0 = <&pwm0_pin_pull_down>; 634}; 635 636&rockchip_suspend { 637 rockchip,pwm-regulator-config = < 638 (0 639 | RKPM_PWM_REGULATOR 640 ) 641 >; 642 643 status = "okay"; 644}; 645 646&saradc { 647 status = "okay"; 648 vref-supply = <&vcc_1v8>; 649}; 650 651&sdio { 652 bus-width = <4>; 653 cap-sd-highspeed; 654 no-sd; 655 no-mmc; 656 ignore-pm-notify; 657 keep-power-in-suspend; 658 non-removable; 659 mmc-pwrseq = <&sdio_pwrseq>; 660 sd-uhs-sdr104; 661 status = "okay"; 662}; 663 664&tsadc { 665 rockchip,hw-tshut-mode = <0>; /* tshut mode 0:CRU 1:GPIO */ 666 rockchip,hw-tshut-polarity = <1>; /* tshut polarity 0:LOW 1:HIGH */ 667 status = "okay"; 668}; 669 670&uart4 { 671 pinctrl-names = "default"; 672 pinctrl-0 = <&uart4_xfer &uart4_cts>; 673 status = "okay"; 674}; 675 676&u2phy { 677 status = "okay"; 678 679 u2phy_otg: otg-port { 680 status = "okay"; 681 }; 682}; 683 684&usb20_otg { 685 status = "okay"; 686}; 687