1// SPDX-License-Identifier: GPL-2.0-only 2/* 3 * Copyright (C) 2012 Texas Instruments Incorporated - https://www.ti.com/ 4 */ 5 6/* 7 * VScom OnRISC 8 * https://www.vscom.de 9 */ 10 11#include "am33xx.dtsi" 12#include <dt-bindings/pwm/pwm.h> 13#include <dt-bindings/interrupt-controller/irq.h> 14 15/ { 16 compatible = "vscom,onrisc", "ti,am33xx"; 17 18 cpus { 19 cpu@0 { 20 cpu0-supply = <&vdd1_reg>; 21 }; 22 }; 23 24 memory@80000000 { 25 device_type = "memory"; 26 reg = <0x80000000 0x10000000>; /* 256 MB */ 27 }; 28 29 vbat: fixedregulator0 { 30 compatible = "regulator-fixed"; 31 regulator-name = "vbat"; 32 regulator-min-microvolt = <5000000>; 33 regulator-max-microvolt = <5000000>; 34 regulator-boot-on; 35 }; 36 37 wl12xx_vmmc: fixedregulator2 { 38 pinctrl-names = "default"; 39 pinctrl-0 = <&wl12xx_gpio>; 40 compatible = "regulator-fixed"; 41 regulator-name = "vwl1271"; 42 regulator-min-microvolt = <3300000>; 43 regulator-max-microvolt = <3300000>; 44 gpio = <&gpio3 8 0>; 45 startup-delay-us = <70000>; 46 enable-active-high; 47 }; 48}; 49 50&am33xx_pinmux { 51 mmc2_pins: mmc2-pins { 52 pinctrl-single,pins = < 53 AM33XX_PADCONF(AM335X_PIN_GPMC_AD8, PIN_INPUT_PULLUP, MUX_MODE2) /* gpmc_ad8.mmc1_dat0_mux0 */ 54 AM33XX_PADCONF(AM335X_PIN_GPMC_AD9, PIN_INPUT_PULLUP, MUX_MODE2) /* gpmc_ad9.mmc1_dat1_mux0 */ 55 AM33XX_PADCONF(AM335X_PIN_GPMC_AD10, PIN_INPUT_PULLUP, MUX_MODE2) /* gpmc_ad10.mmc1_dat2_mux0 */ 56 AM33XX_PADCONF(AM335X_PIN_GPMC_AD11, PIN_INPUT_PULLUP, MUX_MODE2) /* gpmc_ad11.mmc1_dat3_mux0 */ 57 AM33XX_PADCONF(AM335X_PIN_GPMC_CSN1, PIN_INPUT_PULLUP, MUX_MODE2) /* gpmc_csn1.mmc1_clk_mux0 */ 58 AM33XX_PADCONF(AM335X_PIN_GPMC_CSN2, PIN_INPUT_PULLUP, MUX_MODE2) /* gpmc_csn2.mmc1_cmd_mux0 */ 59 AM33XX_PADCONF(AM335X_PIN_EMU0, PIN_INPUT_PULLUP, MUX_MODE7) /* emu0.gpio3[7] */ 60 >; 61 }; 62 63 wl12xx_gpio: wl12xx-gpio-pins { 64 pinctrl-single,pins = < 65 AM33XX_PADCONF(AM335X_PIN_EMU1, PIN_OUTPUT_PULLUP, MUX_MODE7) /* emu1.gpio3[8] */ 66 >; 67 }; 68 69 tps65910_pins: tps65910-pins { 70 pinctrl-single,pins = < 71 AM33XX_PADCONF(AM335X_PIN_GPMC_BEN1, PIN_INPUT_PULLUP, MUX_MODE7) /* gpmc_ben1.gpio1[28] */ 72 >; 73 }; 74 75 i2c1_pins: i2c1-pins { 76 pinctrl-single,pins = < 77 AM33XX_PADCONF(AM335X_PIN_SPI0_D1, PIN_INPUT, MUX_MODE2) /* spi0_d1.i2c1_sda_mux3 */ 78 AM33XX_PADCONF(AM335X_PIN_SPI0_CS0, PIN_INPUT, MUX_MODE2) /* spi0_cs0.i2c1_scl_mux3 */ 79 >; 80 }; 81 82 uart0_pins: uart0-pins { 83 pinctrl-single,pins = < 84 AM33XX_PADCONF(AM335X_PIN_UART0_RXD, PIN_INPUT_PULLUP, MUX_MODE0) 85 AM33XX_PADCONF(AM335X_PIN_UART0_TXD, PIN_OUTPUT_PULLDOWN, MUX_MODE0) 86 >; 87 }; 88 89 cpsw_default: cpsw-default-pins { 90 pinctrl-single,pins = < 91 /* Slave 1 */ 92 AM33XX_PADCONF(AM335X_PIN_MII1_CRS, PIN_INPUT_PULLDOWN, MUX_MODE1) /* mii1_crs.rmii1_crs_dv */ 93 AM33XX_PADCONF(AM335X_PIN_MII1_TX_EN, PIN_OUTPUT_PULLDOWN, MUX_MODE1) /* mii1_tx_en.rmii1_txen */ 94 AM33XX_PADCONF(AM335X_PIN_MII1_TXD1, PIN_OUTPUT_PULLDOWN, MUX_MODE1) /* mii1_txd1.rmii1_txd1 */ 95 AM33XX_PADCONF(AM335X_PIN_MII1_TXD0, PIN_OUTPUT_PULLDOWN, MUX_MODE1) /* mii1_txd0.rmii1_txd0 */ 96 AM33XX_PADCONF(AM335X_PIN_MII1_RXD1, PIN_INPUT_PULLDOWN, MUX_MODE1) /* mii1_rxd1.rmii1_rxd1 */ 97 AM33XX_PADCONF(AM335X_PIN_MII1_RXD0, PIN_INPUT_PULLDOWN, MUX_MODE1) /* mii1_rxd0.rmii1_rxd0 */ 98 AM33XX_PADCONF(AM335X_PIN_RMII1_REF_CLK, PIN_INPUT_PULLDOWN, MUX_MODE0) /* rmii1_ref_clk.rmii1_refclk */ 99 100 101 /* Slave 2 */ 102 AM33XX_PADCONF(AM335X_PIN_GPMC_A0, PIN_OUTPUT_PULLDOWN, MUX_MODE2) /* gpmc_a0.rgmii2_tctl */ 103 AM33XX_PADCONF(AM335X_PIN_GPMC_A1, PIN_INPUT_PULLDOWN, MUX_MODE2) /* gpmc_a1.rgmii2_rctl */ 104 AM33XX_PADCONF(AM335X_PIN_GPMC_A2, PIN_OUTPUT_PULLDOWN, MUX_MODE2) /* gpmc_a2.rgmii2_td3 */ 105 AM33XX_PADCONF(AM335X_PIN_GPMC_A3, PIN_OUTPUT_PULLDOWN, MUX_MODE2) /* gpmc_a3.rgmii2_td2 */ 106 AM33XX_PADCONF(AM335X_PIN_GPMC_A4, PIN_OUTPUT_PULLDOWN, MUX_MODE2) /* gpmc_a4.rgmii2_td1 */ 107 AM33XX_PADCONF(AM335X_PIN_GPMC_A5, PIN_OUTPUT_PULLDOWN, MUX_MODE2) /* gpmc_a5.rgmii2_td0 */ 108 AM33XX_PADCONF(AM335X_PIN_GPMC_A6, PIN_OUTPUT_PULLDOWN, MUX_MODE2) /* gpmc_a6.rgmii2_tclk */ 109 AM33XX_PADCONF(AM335X_PIN_GPMC_A7, PIN_INPUT_PULLDOWN, MUX_MODE2) /* gpmc_a7.rgmii2_rclk */ 110 AM33XX_PADCONF(AM335X_PIN_GPMC_A8, PIN_INPUT_PULLDOWN, MUX_MODE2) /* gpmc_a8.rgmii2_rd3 */ 111 AM33XX_PADCONF(AM335X_PIN_GPMC_A9, PIN_INPUT_PULLDOWN, MUX_MODE2) /* gpmc_a9.rgmii2_rd2 */ 112 AM33XX_PADCONF(AM335X_PIN_GPMC_A10, PIN_INPUT_PULLDOWN, MUX_MODE2) /* gpmc_a10.rgmii2_rd1 */ 113 AM33XX_PADCONF(AM335X_PIN_GPMC_A11, PIN_INPUT_PULLDOWN, MUX_MODE2) /* gpmc_a11.rgmii2_rd0 */ 114 >; 115 }; 116 117 cpsw_sleep: cpsw-sleep-pins { 118 pinctrl-single,pins = < 119 /* Slave 1 reset value */ 120 AM33XX_PADCONF(AM335X_PIN_MII1_CRS, PIN_INPUT_PULLDOWN, MUX_MODE7) 121 AM33XX_PADCONF(AM335X_PIN_MII1_TX_EN, PIN_INPUT_PULLDOWN, MUX_MODE7) 122 AM33XX_PADCONF(AM335X_PIN_MII1_TXD1, PIN_INPUT_PULLDOWN, MUX_MODE7) 123 AM33XX_PADCONF(AM335X_PIN_MII1_TXD0, PIN_INPUT_PULLDOWN, MUX_MODE7) 124 AM33XX_PADCONF(AM335X_PIN_MII1_RXD1, PIN_INPUT_PULLDOWN, MUX_MODE7) 125 AM33XX_PADCONF(AM335X_PIN_MII1_RXD0, PIN_INPUT_PULLDOWN, MUX_MODE7) 126 AM33XX_PADCONF(AM335X_PIN_RMII1_REF_CLK, PIN_INPUT_PULLDOWN, MUX_MODE7) 127 128 /* Slave 2 reset value*/ 129 AM33XX_PADCONF(AM335X_PIN_GPMC_A0, PIN_INPUT_PULLDOWN, MUX_MODE7) 130 AM33XX_PADCONF(AM335X_PIN_GPMC_A1, PIN_INPUT_PULLDOWN, MUX_MODE7) 131 AM33XX_PADCONF(AM335X_PIN_GPMC_A2, PIN_INPUT_PULLDOWN, MUX_MODE7) 132 AM33XX_PADCONF(AM335X_PIN_GPMC_A3, PIN_INPUT_PULLDOWN, MUX_MODE7) 133 AM33XX_PADCONF(AM335X_PIN_GPMC_A4, PIN_INPUT_PULLDOWN, MUX_MODE7) 134 AM33XX_PADCONF(AM335X_PIN_GPMC_A5, PIN_INPUT_PULLDOWN, MUX_MODE7) 135 AM33XX_PADCONF(AM335X_PIN_GPMC_A6, PIN_INPUT_PULLDOWN, MUX_MODE7) 136 AM33XX_PADCONF(AM335X_PIN_GPMC_A7, PIN_INPUT_PULLDOWN, MUX_MODE7) 137 AM33XX_PADCONF(AM335X_PIN_GPMC_A8, PIN_INPUT_PULLDOWN, MUX_MODE7) 138 AM33XX_PADCONF(AM335X_PIN_GPMC_A9, PIN_INPUT_PULLDOWN, MUX_MODE7) 139 AM33XX_PADCONF(AM335X_PIN_GPMC_A10, PIN_INPUT_PULLDOWN, MUX_MODE7) 140 AM33XX_PADCONF(AM335X_PIN_GPMC_A11, PIN_INPUT_PULLDOWN, MUX_MODE7) 141 >; 142 }; 143 144 davinci_mdio_default: davinci-mdio-default-pins { 145 pinctrl-single,pins = < 146 /* MDIO */ 147 AM33XX_PADCONF(AM335X_PIN_MDIO, PIN_INPUT_PULLUP | SLEWCTRL_FAST, MUX_MODE0) /* mdio_data.mdio_data */ 148 AM33XX_PADCONF(AM335X_PIN_MDC, PIN_OUTPUT_PULLUP, MUX_MODE0) /* mdio_clk.mdio_clk */ 149 >; 150 }; 151 152 davinci_mdio_sleep: davinci-mdio-sleep-pins { 153 pinctrl-single,pins = < 154 /* MDIO reset value */ 155 AM33XX_PADCONF(AM335X_PIN_MDIO, PIN_INPUT_PULLDOWN, MUX_MODE7) 156 AM33XX_PADCONF(AM335X_PIN_MDC, PIN_INPUT_PULLDOWN, MUX_MODE7) 157 >; 158 }; 159 160 nandflash_pins_s0: nandflash-s0-pins { 161 pinctrl-single,pins = < 162 AM33XX_PADCONF(AM335X_PIN_GPMC_AD0, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_ad0.gpmc_ad0 */ 163 AM33XX_PADCONF(AM335X_PIN_GPMC_AD1, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_ad1.gpmc_ad1 */ 164 AM33XX_PADCONF(AM335X_PIN_GPMC_AD2, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_ad2.gpmc_ad2 */ 165 AM33XX_PADCONF(AM335X_PIN_GPMC_AD3, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_ad3.gpmc_ad3 */ 166 AM33XX_PADCONF(AM335X_PIN_GPMC_AD4, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_ad4.gpmc_ad4 */ 167 AM33XX_PADCONF(AM335X_PIN_GPMC_AD5, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_ad5.gpmc_ad5 */ 168 AM33XX_PADCONF(AM335X_PIN_GPMC_AD6, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_ad6.gpmc_ad6 */ 169 AM33XX_PADCONF(AM335X_PIN_GPMC_AD7, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_ad7.gpmc_ad7 */ 170 AM33XX_PADCONF(AM335X_PIN_GPMC_WAIT0, PIN_INPUT_PULLUP, MUX_MODE0) /* gpmc_wait0.gpmc_wait0 */ 171 AM33XX_PADCONF(AM335X_PIN_GPMC_WPN, PIN_INPUT_PULLUP, MUX_MODE7) /* gpmc_wpn.gpio0_31 */ 172 AM33XX_PADCONF(AM335X_PIN_GPMC_CSN0, PIN_OUTPUT, MUX_MODE0) /* gpmc_csn0.gpmc_csn0 */ 173 AM33XX_PADCONF(AM335X_PIN_GPMC_ADVN_ALE, PIN_OUTPUT, MUX_MODE0) /* gpmc_advn_ale.gpmc_advn_ale */ 174 AM33XX_PADCONF(AM335X_PIN_GPMC_OEN_REN, PIN_OUTPUT, MUX_MODE0) /* gpmc_oen_ren.gpmc_oen_ren */ 175 AM33XX_PADCONF(AM335X_PIN_GPMC_WEN, PIN_OUTPUT, MUX_MODE0) /* gpmc_wen.gpmc_wen */ 176 AM33XX_PADCONF(AM335X_PIN_GPMC_BEN0_CLE, PIN_OUTPUT, MUX_MODE0) /* gpmc_be0n_cle.gpmc_be0n_cle */ 177 >; 178 }; 179}; 180 181&elm { 182 status = "okay"; 183}; 184 185&gpmc { 186 pinctrl-names = "default"; 187 pinctrl-0 = <&nandflash_pins_s0>; 188 ranges = <0 0 0x08000000 0x10000000>; /* CS0: NAND */ 189 status = "okay"; 190 191 nand@0,0 { 192 compatible = "ti,omap2-nand"; 193 reg = <0 0 4>; /* CS0, offset 0, IO size 4 */ 194 interrupt-parent = <&gpmc>; 195 interrupts = <0 IRQ_TYPE_NONE>, /* fifoevent */ 196 <1 IRQ_TYPE_NONE>; /* termcount */ 197 rb-gpios = <&gpmc 0 GPIO_ACTIVE_HIGH>; /* gpmc_wait0 */ 198 nand-bus-width = <8>; 199 ti,nand-ecc-opt = "bch8"; 200 ti,nand-xfer-type = "prefetch-dma"; 201 202 gpmc,device-width = <1>; 203 gpmc,sync-clk-ps = <0>; 204 gpmc,cs-on-ns = <0>; 205 gpmc,cs-rd-off-ns = <44>; 206 gpmc,cs-wr-off-ns = <44>; 207 gpmc,adv-on-ns = <6>; 208 gpmc,adv-rd-off-ns = <34>; 209 gpmc,adv-wr-off-ns = <44>; 210 gpmc,we-on-ns = <0>; 211 gpmc,we-off-ns = <40>; 212 gpmc,oe-on-ns = <0>; 213 gpmc,oe-off-ns = <54>; 214 gpmc,access-ns = <64>; 215 gpmc,rd-cycle-ns = <82>; 216 gpmc,wr-cycle-ns = <82>; 217 gpmc,bus-turnaround-ns = <0>; 218 gpmc,cycle2cycle-delay-ns = <0>; 219 gpmc,clk-activation-ns = <0>; 220 gpmc,wr-access-ns = <40>; 221 gpmc,wr-data-mux-bus-ns = <0>; 222 223 #address-cells = <1>; 224 #size-cells = <1>; 225 ti,elm-id = <&elm>; 226 }; 227}; 228 229&uart0 { 230 pinctrl-names = "default"; 231 pinctrl-0 = <&uart0_pins>; 232 233 status = "okay"; 234}; 235 236&i2c1 { 237 pinctrl-names = "default"; 238 pinctrl-0 = <&i2c1_pins>; 239 240 status = "okay"; 241 clock-frequency = <400000>; 242 243 tps: tps@2d { 244 reg = <0x2d>; 245 gpio-controller; 246 #gpio-cells = <2>; 247 interrupt-parent = <&gpio1>; 248 interrupts = <28 IRQ_TYPE_EDGE_RISING>; 249 pinctrl-names = "default"; 250 pinctrl-0 = <&tps65910_pins>; 251 }; 252 253 eeprom@50 { 254 compatible = "atmel,24c02"; 255 pagesize = <8>; 256 reg = <0x50>; 257 }; 258}; 259 260#include "../../tps65910.dtsi" 261 262&tps { 263 vcc1-supply = <&vbat>; 264 vcc2-supply = <&vbat>; 265 vcc3-supply = <&vbat>; 266 vcc4-supply = <&vbat>; 267 vcc5-supply = <&vbat>; 268 vcc6-supply = <&vbat>; 269 vcc7-supply = <&vbat>; 270 vccio-supply = <&vbat>; 271 272 ti,en-ck32k-xtal = <1>; 273 274 regulators { 275 vrtc_reg: regulator@0 { 276 regulator-always-on; 277 }; 278 279 vio_reg: regulator@1 { 280 regulator-always-on; 281 }; 282 283 vdd1_reg: regulator@2 { 284 /* VDD_MPU voltage limits 0.95V - 1.26V with +/-4% tolerance */ 285 regulator-name = "vdd_mpu"; 286 regulator-min-microvolt = <912500>; 287 regulator-max-microvolt = <1351500>; 288 regulator-boot-on; 289 regulator-always-on; 290 }; 291 292 vdd2_reg: regulator@3 { 293 /* VDD_CORE voltage limits 0.95V - 1.1V with +/-4% tolerance */ 294 regulator-name = "vdd_core"; 295 regulator-min-microvolt = <912500>; 296 regulator-max-microvolt = <1150000>; 297 regulator-boot-on; 298 regulator-always-on; 299 }; 300 301 vdd3_reg: regulator@4 { 302 regulator-always-on; 303 }; 304 305 vdig1_reg: regulator@5 { 306 regulator-always-on; 307 }; 308 309 vdig2_reg: regulator@6 { 310 regulator-always-on; 311 }; 312 313 vpll_reg: regulator@7 { 314 regulator-always-on; 315 }; 316 317 vdac_reg: regulator@8 { 318 regulator-always-on; 319 }; 320 321 vaux1_reg: regulator@9 { 322 regulator-always-on; 323 }; 324 325 vaux2_reg: regulator@10 { 326 regulator-always-on; 327 }; 328 329 vaux33_reg: regulator@11 { 330 regulator-always-on; 331 }; 332 333 vmmc_reg: regulator@12 { 334 regulator-min-microvolt = <1800000>; 335 regulator-max-microvolt = <3300000>; 336 regulator-always-on; 337 }; 338 }; 339}; 340 341&mac_sw { 342 pinctrl-names = "default", "sleep"; 343 pinctrl-0 = <&cpsw_default>; 344 pinctrl-1 = <&cpsw_sleep>; 345 346 status = "okay"; 347}; 348 349&davinci_mdio_sw { 350 status = "okay"; 351 pinctrl-names = "default", "sleep"; 352 pinctrl-0 = <&davinci_mdio_default>; 353 pinctrl-1 = <&davinci_mdio_sleep>; 354 355 phy1: ethernet-phy@1 { 356 reg = <7>; 357 eee-broken-100tx; 358 eee-broken-1000t; 359 }; 360}; 361 362&mmc1 { 363 vmmc-supply = <&vmmc_reg>; 364 status = "okay"; 365}; 366 367&mmc2 { 368 status = "okay"; 369 vmmc-supply = <&wl12xx_vmmc>; 370 non-removable; 371 bus-width = <4>; 372 cap-power-off-card; 373 pinctrl-names = "default"; 374 pinctrl-0 = <&mmc2_pins>; 375 376 #address-cells = <1>; 377 #size-cells = <0>; 378 wlcore: wlcore@2 { 379 compatible = "ti,wl1835"; 380 reg = <2>; 381 interrupt-parent = <&gpio3>; 382 interrupts = <7 IRQ_TYPE_EDGE_RISING>; 383 }; 384}; 385 386&sham { 387 status = "okay"; 388}; 389 390&aes { 391 status = "okay"; 392}; 393 394&gpio0_target { 395 ti,no-reset-on-init; 396}; 397 398&gpio3_target { 399 ti,no-reset-on-init; 400}; 401