1724ba675SRob Herring// SPDX-License-Identifier: (GPL-2.0+ OR MIT) 2724ba675SRob Herring/* 3724ba675SRob Herring * Device tree file for Phytec phyCORE-RK3288 SoM 4724ba675SRob Herring * Copyright (C) 2017 PHYTEC Messtechnik GmbH 5724ba675SRob Herring * Author: Wadim Egorov <w.egorov@phytec.de> 6724ba675SRob Herring */ 7724ba675SRob Herring 8724ba675SRob Herring#include <dt-bindings/net/ti-dp83867.h> 9724ba675SRob Herring#include "rk3288.dtsi" 10724ba675SRob Herring 11724ba675SRob Herring/ { 12724ba675SRob Herring model = "Phytec RK3288 phyCORE"; 13724ba675SRob Herring compatible = "phytec,rk3288-phycore-som", "rockchip,rk3288"; 14724ba675SRob Herring 15724ba675SRob Herring /* 16724ba675SRob Herring * Set the minimum memory size here and 17724ba675SRob Herring * let the bootloader set the real size. 18724ba675SRob Herring */ 19724ba675SRob Herring memory { 20724ba675SRob Herring device_type = "memory"; 21724ba675SRob Herring reg = <0x0 0x0 0x0 0x8000000>; 22724ba675SRob Herring }; 23724ba675SRob Herring 24724ba675SRob Herring aliases { 25724ba675SRob Herring rtc0 = &i2c_rtc; 26724ba675SRob Herring rtc1 = &rk818; 27724ba675SRob Herring }; 28724ba675SRob Herring 29724ba675SRob Herring ext_gmac: external-gmac-clock { 30724ba675SRob Herring compatible = "fixed-clock"; 31724ba675SRob Herring #clock-cells = <0>; 32724ba675SRob Herring clock-frequency = <125000000>; 33724ba675SRob Herring clock-output-names = "ext_gmac"; 34724ba675SRob Herring }; 35724ba675SRob Herring 36724ba675SRob Herring leds: user-leds { 37724ba675SRob Herring compatible = "gpio-leds"; 38724ba675SRob Herring pinctrl-names = "default"; 39724ba675SRob Herring pinctrl-0 = <&user_led_pin>; 40724ba675SRob Herring 41724ba675SRob Herring user_led: led-0 { 42724ba675SRob Herring label = "green_led"; 43724ba675SRob Herring gpios = <&gpio7 2 GPIO_ACTIVE_HIGH>; 44724ba675SRob Herring linux,default-trigger = "heartbeat"; 45724ba675SRob Herring default-state = "keep"; 46724ba675SRob Herring }; 47724ba675SRob Herring }; 48724ba675SRob Herring 49*2c3944d9SJohan Jonker vdd_emmc_io: regulator-vdd-emmc-io { 50724ba675SRob Herring compatible = "regulator-fixed"; 51724ba675SRob Herring regulator-name = "vdd_emmc_io"; 52724ba675SRob Herring regulator-min-microvolt = <1800000>; 53724ba675SRob Herring regulator-max-microvolt = <1800000>; 54724ba675SRob Herring vin-supply = <&vdd_3v3_io>; 55724ba675SRob Herring }; 56724ba675SRob Herring 57*2c3944d9SJohan Jonker vdd_in_otg_out: regulator-vdd-in-otg-out { 58724ba675SRob Herring compatible = "regulator-fixed"; 59724ba675SRob Herring regulator-name = "vdd_in_otg_out"; 60724ba675SRob Herring regulator-always-on; 61724ba675SRob Herring regulator-boot-on; 62724ba675SRob Herring regulator-min-microvolt = <5000000>; 63724ba675SRob Herring regulator-max-microvolt = <5000000>; 64724ba675SRob Herring }; 65724ba675SRob Herring 66*2c3944d9SJohan Jonker vdd_misc_1v8: regulator-vdd-misc-1v8 { 67724ba675SRob Herring compatible = "regulator-fixed"; 68724ba675SRob Herring regulator-name = "vdd_misc_1v8"; 69724ba675SRob Herring regulator-always-on; 70724ba675SRob Herring regulator-boot-on; 71724ba675SRob Herring regulator-min-microvolt = <1800000>; 72724ba675SRob Herring regulator-max-microvolt = <1800000>; 73724ba675SRob Herring }; 74724ba675SRob Herring}; 75724ba675SRob Herring 76724ba675SRob Herring&emmc { 77724ba675SRob Herring status = "okay"; 78724ba675SRob Herring bus-width = <8>; 79724ba675SRob Herring cap-mmc-highspeed; 80724ba675SRob Herring disable-wp; 81724ba675SRob Herring non-removable; 82724ba675SRob Herring pinctrl-names = "default"; 83724ba675SRob Herring pinctrl-0 = <&emmc_clk &emmc_cmd &emmc_pwr &emmc_bus8>; 84724ba675SRob Herring vmmc-supply = <&vdd_3v3_io>; 85724ba675SRob Herring vqmmc-supply = <&vdd_emmc_io>; 86724ba675SRob Herring}; 87724ba675SRob Herring 88724ba675SRob Herring&gmac { 89724ba675SRob Herring assigned-clocks = <&cru SCLK_MAC>; 90724ba675SRob Herring assigned-clock-parents = <&ext_gmac>; 91724ba675SRob Herring clock_in_out = "input"; 92724ba675SRob Herring pinctrl-names = "default"; 93724ba675SRob Herring pinctrl-0 = <&rgmii_pins &phy_rst &phy_int>; 94724ba675SRob Herring phy-handle = <&phy0>; 95724ba675SRob Herring phy-supply = <&vdd_eth_2v5>; 96724ba675SRob Herring phy-mode = "rgmii-id"; 97724ba675SRob Herring snps,reset-active-low; 98724ba675SRob Herring snps,reset-delays-us = <0 10000 1000000>; 99724ba675SRob Herring snps,reset-gpio = <&gpio4 8 GPIO_ACTIVE_HIGH>; 100724ba675SRob Herring tx_delay = <0x0>; 101724ba675SRob Herring rx_delay = <0x0>; 102724ba675SRob Herring 103724ba675SRob Herring mdio0 { 104724ba675SRob Herring compatible = "snps,dwmac-mdio"; 105724ba675SRob Herring #address-cells = <1>; 106724ba675SRob Herring #size-cells = <0>; 107724ba675SRob Herring 108724ba675SRob Herring phy0: ethernet-phy@0 { 109724ba675SRob Herring compatible = "ethernet-phy-ieee802.3-c22"; 110724ba675SRob Herring reg = <0>; 111724ba675SRob Herring interrupt-parent = <&gpio4>; 112724ba675SRob Herring interrupts = <2 IRQ_TYPE_EDGE_FALLING>; 113724ba675SRob Herring ti,rx-internal-delay = <DP83867_RGMIIDCTL_2_00_NS>; 114724ba675SRob Herring ti,tx-internal-delay = <DP83867_RGMIIDCTL_2_00_NS>; 115724ba675SRob Herring ti,fifo-depth = <DP83867_PHYCR_FIFO_DEPTH_4_B_NIB>; 116724ba675SRob Herring enet-phy-lane-no-swap; 117724ba675SRob Herring ti,clk-output-sel = <DP83867_CLK_O_SEL_CHN_A_TCLK>; 118724ba675SRob Herring }; 119724ba675SRob Herring }; 120724ba675SRob Herring}; 121724ba675SRob Herring 122724ba675SRob Herring&hdmi { 123724ba675SRob Herring ddc-i2c-bus = <&i2c5>; 124724ba675SRob Herring}; 125724ba675SRob Herring 126724ba675SRob Herring&io_domains { 127724ba675SRob Herring status = "okay"; 128724ba675SRob Herring sdcard-supply = <&vdd_io_sd>; 129724ba675SRob Herring flash0-supply = <&vdd_emmc_io>; 130724ba675SRob Herring flash1-supply = <&vdd_misc_1v8>; 131724ba675SRob Herring gpio1830-supply = <&vdd_3v3_io>; 132724ba675SRob Herring gpio30-supply = <&vdd_3v3_io>; 133724ba675SRob Herring bb-supply = <&vdd_3v3_io>; 134724ba675SRob Herring dvp-supply = <&vdd_3v3_io>; 135724ba675SRob Herring lcdc-supply = <&vdd_3v3_io>; 136724ba675SRob Herring wifi-supply = <&vdd_3v3_io>; 137724ba675SRob Herring audio-supply = <&vdd_3v3_io>; 138724ba675SRob Herring}; 139724ba675SRob Herring 140724ba675SRob Herring&i2c0 { 141724ba675SRob Herring status = "okay"; 142724ba675SRob Herring clock-frequency = <400000>; 143724ba675SRob Herring 144724ba675SRob Herring rk818: pmic@1c { 145724ba675SRob Herring compatible = "rockchip,rk818"; 146724ba675SRob Herring reg = <0x1c>; 147724ba675SRob Herring interrupt-parent = <&gpio0>; 148724ba675SRob Herring interrupts = <4 IRQ_TYPE_LEVEL_LOW>; 149724ba675SRob Herring pinctrl-names = "default"; 150724ba675SRob Herring pinctrl-0 = <&pmic_int>; 151724ba675SRob Herring rockchip,system-power-controller; 152724ba675SRob Herring wakeup-source; 153724ba675SRob Herring #clock-cells = <1>; 154724ba675SRob Herring 155724ba675SRob Herring vcc1-supply = <&vdd_sys>; 156724ba675SRob Herring vcc2-supply = <&vdd_sys>; 157724ba675SRob Herring vcc3-supply = <&vdd_sys>; 158724ba675SRob Herring vcc4-supply = <&vdd_sys>; 159724ba675SRob Herring boost-supply = <&vdd_in_otg_out>; 160724ba675SRob Herring vcc6-supply = <&vdd_sys>; 161724ba675SRob Herring vcc7-supply = <&vdd_misc_1v8>; 162724ba675SRob Herring vcc8-supply = <&vdd_misc_1v8>; 163724ba675SRob Herring vcc9-supply = <&vdd_3v3_io>; 164724ba675SRob Herring vddio-supply = <&vdd_3v3_io>; 165724ba675SRob Herring 166724ba675SRob Herring regulators { 167724ba675SRob Herring vdd_log: DCDC_REG1 { 168724ba675SRob Herring regulator-name = "vdd_log"; 169724ba675SRob Herring regulator-always-on; 170724ba675SRob Herring regulator-boot-on; 171724ba675SRob Herring regulator-min-microvolt = <1100000>; 172724ba675SRob Herring regulator-max-microvolt = <1100000>; 173724ba675SRob Herring regulator-state-mem { 174724ba675SRob Herring regulator-off-in-suspend; 175724ba675SRob Herring }; 176724ba675SRob Herring }; 177724ba675SRob Herring 178724ba675SRob Herring vdd_gpu: DCDC_REG2 { 179724ba675SRob Herring regulator-name = "vdd_gpu"; 180724ba675SRob Herring regulator-always-on; 181724ba675SRob Herring regulator-boot-on; 182724ba675SRob Herring regulator-min-microvolt = <800000>; 183724ba675SRob Herring regulator-max-microvolt = <1250000>; 184724ba675SRob Herring regulator-state-mem { 185724ba675SRob Herring regulator-on-in-suspend; 186724ba675SRob Herring regulator-suspend-microvolt = <1000000>; 187724ba675SRob Herring }; 188724ba675SRob Herring }; 189724ba675SRob Herring 190724ba675SRob Herring vcc_ddr: DCDC_REG3 { 191724ba675SRob Herring regulator-name = "vcc_ddr"; 192724ba675SRob Herring regulator-always-on; 193724ba675SRob Herring regulator-boot-on; 194724ba675SRob Herring regulator-state-mem { 195724ba675SRob Herring regulator-on-in-suspend; 196724ba675SRob Herring }; 197724ba675SRob Herring }; 198724ba675SRob Herring 199724ba675SRob Herring vdd_3v3_io: DCDC_REG4 { 200724ba675SRob Herring regulator-name = "vdd_3v3_io"; 201724ba675SRob Herring regulator-always-on; 202724ba675SRob Herring regulator-boot-on; 203724ba675SRob Herring regulator-min-microvolt = <3300000>; 204724ba675SRob Herring regulator-max-microvolt = <3300000>; 205724ba675SRob Herring regulator-state-mem { 206724ba675SRob Herring regulator-on-in-suspend; 207724ba675SRob Herring regulator-suspend-microvolt = <3300000>; 208724ba675SRob Herring }; 209724ba675SRob Herring }; 210724ba675SRob Herring 211724ba675SRob Herring vdd_sys: DCDC_BOOST { 212724ba675SRob Herring regulator-name = "vdd_sys"; 213724ba675SRob Herring regulator-always-on; 214724ba675SRob Herring regulator-boot-on; 215724ba675SRob Herring regulator-min-microvolt = <5000000>; 216724ba675SRob Herring regulator-max-microvolt = <5000000>; 217724ba675SRob Herring regulator-state-mem { 218724ba675SRob Herring regulator-on-in-suspend; 219724ba675SRob Herring regulator-suspend-microvolt = <5000000>; 220724ba675SRob Herring }; 221724ba675SRob Herring }; 222724ba675SRob Herring 223724ba675SRob Herring /* vcc9 */ 224724ba675SRob Herring vdd_sd: SWITCH_REG { 225724ba675SRob Herring regulator-name = "vdd_sd"; 226724ba675SRob Herring regulator-always-on; 227724ba675SRob Herring regulator-boot-on; 228724ba675SRob Herring regulator-state-mem { 229724ba675SRob Herring regulator-off-in-suspend; 230724ba675SRob Herring }; 231724ba675SRob Herring }; 232724ba675SRob Herring 233724ba675SRob Herring /* vcc6 */ 234724ba675SRob Herring vdd_eth_2v5: LDO_REG2 { 235724ba675SRob Herring regulator-name = "vdd_eth_2v5"; 236724ba675SRob Herring regulator-always-on; 237724ba675SRob Herring regulator-boot-on; 238724ba675SRob Herring regulator-min-microvolt = <2500000>; 239724ba675SRob Herring regulator-max-microvolt = <2500000>; 240724ba675SRob Herring regulator-state-mem { 241724ba675SRob Herring regulator-on-in-suspend; 242724ba675SRob Herring regulator-suspend-microvolt = <2500000>; 243724ba675SRob Herring }; 244724ba675SRob Herring }; 245724ba675SRob Herring 246724ba675SRob Herring /* vcc7 */ 247724ba675SRob Herring vdd_1v0: LDO_REG3 { 248724ba675SRob Herring regulator-name = "vdd_1v0"; 249724ba675SRob Herring regulator-always-on; 250724ba675SRob Herring regulator-boot-on; 251724ba675SRob Herring regulator-min-microvolt = <1000000>; 252724ba675SRob Herring regulator-max-microvolt = <1000000>; 253724ba675SRob Herring regulator-state-mem { 254724ba675SRob Herring regulator-on-in-suspend; 255724ba675SRob Herring regulator-suspend-microvolt = <1000000>; 256724ba675SRob Herring }; 257724ba675SRob Herring }; 258724ba675SRob Herring 259724ba675SRob Herring /* vcc8 */ 260724ba675SRob Herring vdd_1v8_lcd_ldo: LDO_REG4 { 261724ba675SRob Herring regulator-name = "vdd_1v8_lcd_ldo"; 262724ba675SRob Herring regulator-always-on; 263724ba675SRob Herring regulator-boot-on; 264724ba675SRob Herring regulator-min-microvolt = <1800000>; 265724ba675SRob Herring regulator-max-microvolt = <1800000>; 266724ba675SRob Herring regulator-state-mem { 267724ba675SRob Herring regulator-on-in-suspend; 268724ba675SRob Herring regulator-suspend-microvolt = <1800000>; 269724ba675SRob Herring }; 270724ba675SRob Herring }; 271724ba675SRob Herring 272724ba675SRob Herring /* vcc8 */ 273724ba675SRob Herring vdd_1v0_lcd: LDO_REG6 { 274724ba675SRob Herring regulator-name = "vdd_1v0_lcd"; 275724ba675SRob Herring regulator-always-on; 276724ba675SRob Herring regulator-boot-on; 277724ba675SRob Herring regulator-min-microvolt = <1000000>; 278724ba675SRob Herring regulator-max-microvolt = <1000000>; 279724ba675SRob Herring regulator-state-mem { 280724ba675SRob Herring regulator-on-in-suspend; 281724ba675SRob Herring regulator-suspend-microvolt = <1000000>; 282724ba675SRob Herring }; 283724ba675SRob Herring }; 284724ba675SRob Herring 285724ba675SRob Herring /* vcc7 */ 286724ba675SRob Herring vdd_1v8_ldo: LDO_REG7 { 287724ba675SRob Herring regulator-name = "vdd_1v8_ldo"; 288724ba675SRob Herring regulator-always-on; 289724ba675SRob Herring regulator-boot-on; 290724ba675SRob Herring regulator-min-microvolt = <1800000>; 291724ba675SRob Herring regulator-max-microvolt = <1800000>; 292724ba675SRob Herring regulator-state-mem { 293724ba675SRob Herring regulator-off-in-suspend; 294724ba675SRob Herring regulator-suspend-microvolt = <1800000>; 295724ba675SRob Herring }; 296724ba675SRob Herring }; 297724ba675SRob Herring 298724ba675SRob Herring /* vcc9 */ 299724ba675SRob Herring vdd_io_sd: LDO_REG9 { 300724ba675SRob Herring regulator-name = "vdd_io_sd"; 301724ba675SRob Herring regulator-always-on; 302724ba675SRob Herring regulator-boot-on; 303724ba675SRob Herring regulator-min-microvolt = <1800000>; 304724ba675SRob Herring regulator-max-microvolt = <3300000>; 305724ba675SRob Herring regulator-state-mem { 306724ba675SRob Herring regulator-off-in-suspend; 307724ba675SRob Herring }; 308724ba675SRob Herring }; 309724ba675SRob Herring }; 310724ba675SRob Herring }; 311724ba675SRob Herring 312724ba675SRob Herring /* M24C32-D */ 313724ba675SRob Herring i2c_eeprom: eeprom@50 { 314724ba675SRob Herring compatible = "atmel,24c32"; 315724ba675SRob Herring reg = <0x50>; 316724ba675SRob Herring pagesize = <32>; 317724ba675SRob Herring }; 318724ba675SRob Herring 319724ba675SRob Herring vdd_cpu: regulator@60 { 320724ba675SRob Herring compatible = "fcs,fan53555"; 321724ba675SRob Herring reg = <0x60>; 322724ba675SRob Herring fcs,suspend-voltage-selector = <1>; 323724ba675SRob Herring regulator-always-on; 324724ba675SRob Herring regulator-boot-on; 325724ba675SRob Herring regulator-enable-ramp-delay = <300>; 326724ba675SRob Herring regulator-name = "vdd_cpu"; 327724ba675SRob Herring regulator-min-microvolt = <800000>; 328724ba675SRob Herring regulator-max-microvolt = <1430000>; 329724ba675SRob Herring regulator-ramp-delay = <8000>; 330724ba675SRob Herring vin-supply = <&vdd_sys>; 331724ba675SRob Herring }; 332724ba675SRob Herring}; 333724ba675SRob Herring 334724ba675SRob Herring&pinctrl { 335724ba675SRob Herring pcfg_output_high: pcfg-output-high { 336724ba675SRob Herring output-high; 337724ba675SRob Herring }; 338724ba675SRob Herring 339724ba675SRob Herring emmc { 340724ba675SRob Herring /* 341724ba675SRob Herring * We run eMMC at max speed; bump up drive strength. 342724ba675SRob Herring * We also have external pulls, so disable the internal ones. 343724ba675SRob Herring */ 344724ba675SRob Herring emmc_clk: emmc-clk { 345724ba675SRob Herring rockchip,pins = <3 RK_PC2 2 &pcfg_pull_none_12ma>; 346724ba675SRob Herring }; 347724ba675SRob Herring 348724ba675SRob Herring emmc_cmd: emmc-cmd { 349724ba675SRob Herring rockchip,pins = <3 RK_PC0 2 &pcfg_pull_none_12ma>; 350724ba675SRob Herring }; 351724ba675SRob Herring 352724ba675SRob Herring emmc_bus8: emmc-bus8 { 353724ba675SRob Herring rockchip,pins = <3 RK_PA0 2 &pcfg_pull_none_12ma>, 354724ba675SRob Herring <3 RK_PA1 2 &pcfg_pull_none_12ma>, 355724ba675SRob Herring <3 RK_PA2 2 &pcfg_pull_none_12ma>, 356724ba675SRob Herring <3 RK_PA3 2 &pcfg_pull_none_12ma>, 357724ba675SRob Herring <3 RK_PA4 2 &pcfg_pull_none_12ma>, 358724ba675SRob Herring <3 RK_PA5 2 &pcfg_pull_none_12ma>, 359724ba675SRob Herring <3 RK_PA6 2 &pcfg_pull_none_12ma>, 360724ba675SRob Herring <3 RK_PA7 2 &pcfg_pull_none_12ma>; 361724ba675SRob Herring }; 362724ba675SRob Herring }; 363724ba675SRob Herring 364724ba675SRob Herring gmac { 365724ba675SRob Herring phy_int: phy-int { 366724ba675SRob Herring rockchip,pins = <4 RK_PA2 RK_FUNC_GPIO &pcfg_pull_up>; 367724ba675SRob Herring }; 368724ba675SRob Herring 369724ba675SRob Herring phy_rst: phy-rst { 370724ba675SRob Herring rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_output_high>; 371724ba675SRob Herring }; 372724ba675SRob Herring }; 373724ba675SRob Herring 374724ba675SRob Herring leds { 375724ba675SRob Herring user_led_pin: user-led-pin { 376724ba675SRob Herring rockchip,pins = <7 RK_PA2 RK_FUNC_GPIO &pcfg_output_high>; 377724ba675SRob Herring }; 378724ba675SRob Herring }; 379724ba675SRob Herring 380724ba675SRob Herring pmic { 381724ba675SRob Herring pmic_int: pmic-int { 382724ba675SRob Herring rockchip,pins = <0 RK_PA4 RK_FUNC_GPIO &pcfg_pull_up>; 383724ba675SRob Herring }; 384724ba675SRob Herring 385724ba675SRob Herring /* Pin for switching state between sleep and non-sleep state */ 386724ba675SRob Herring pmic_sleep: pmic-sleep { 387724ba675SRob Herring rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_up>; 388724ba675SRob Herring }; 389724ba675SRob Herring }; 390724ba675SRob Herring}; 391724ba675SRob Herring 392724ba675SRob Herring&pwm1 { 393724ba675SRob Herring status = "okay"; 394724ba675SRob Herring}; 395724ba675SRob Herring 396724ba675SRob Herring&saradc { 397724ba675SRob Herring status = "okay"; 398724ba675SRob Herring vref-supply = <&vdd_1v8_ldo>; 399724ba675SRob Herring}; 400724ba675SRob Herring 401724ba675SRob Herring&spi2 { 402724ba675SRob Herring status = "okay"; 403724ba675SRob Herring 404724ba675SRob Herring serial_flash: flash@0 { 405724ba675SRob Herring compatible = "micron,n25q128a13", "jedec,spi-nor"; 406724ba675SRob Herring reg = <0x0>; 407724ba675SRob Herring spi-max-frequency = <50000000>; 408724ba675SRob Herring m25p,fast-read; 409724ba675SRob Herring #address-cells = <1>; 410724ba675SRob Herring #size-cells = <1>; 411724ba675SRob Herring status = "okay"; 412724ba675SRob Herring }; 413724ba675SRob Herring}; 414724ba675SRob Herring 415724ba675SRob Herring&tsadc { 416724ba675SRob Herring status = "okay"; 417724ba675SRob Herring rockchip,hw-tshut-mode = <0>; 418724ba675SRob Herring rockchip,hw-tshut-polarity = <0>; 419724ba675SRob Herring}; 420724ba675SRob Herring 421724ba675SRob Herring&vopb { 422724ba675SRob Herring status = "okay"; 423724ba675SRob Herring}; 424724ba675SRob Herring 425724ba675SRob Herring&vopb_mmu { 426724ba675SRob Herring status = "okay"; 427724ba675SRob Herring}; 428724ba675SRob Herring 429724ba675SRob Herring&vopl { 430724ba675SRob Herring status = "okay"; 431724ba675SRob Herring}; 432724ba675SRob Herring 433724ba675SRob Herring&vopl_mmu { 434724ba675SRob Herring status = "okay"; 435724ba675SRob Herring}; 436724ba675SRob Herring 437724ba675SRob Herring&wdt { 438724ba675SRob Herring status = "okay"; 439724ba675SRob Herring}; 440