1*3443c1c4SWadim Egorov// SPDX-License-Identifier: GPL-2.0 2*3443c1c4SWadim Egorov/* 3*3443c1c4SWadim Egorov * Copyright (C) 2022 - 2023 PHYTEC Messtechnik GmbH 4*3443c1c4SWadim Egorov * Author: Wadim Egorov <w.egorov@phytec.de> 5*3443c1c4SWadim Egorov * 6*3443c1c4SWadim Egorov * Product homepage: 7*3443c1c4SWadim Egorov * https://www.phytec.com/product/phyboard-am62x 8*3443c1c4SWadim Egorov */ 9*3443c1c4SWadim Egorov 10*3443c1c4SWadim Egorov#include <dt-bindings/gpio/gpio.h> 11*3443c1c4SWadim Egorov#include <dt-bindings/input/input.h> 12*3443c1c4SWadim Egorov#include <dt-bindings/leds/common.h> 13*3443c1c4SWadim Egorov#include <dt-bindings/net/ti-dp83867.h> 14*3443c1c4SWadim Egorov#include "k3-am625.dtsi" 15*3443c1c4SWadim Egorov#include "k3-am62-phycore-som.dtsi" 16*3443c1c4SWadim Egorov 17*3443c1c4SWadim Egorov/ { 18*3443c1c4SWadim Egorov compatible = "phytec,am625-phyboard-lyra-rdk", 19*3443c1c4SWadim Egorov "phytec,am62-phycore-som", "ti,am625"; 20*3443c1c4SWadim Egorov model = "PHYTEC phyBOARD-Lyra AM625"; 21*3443c1c4SWadim Egorov 22*3443c1c4SWadim Egorov aliases { 23*3443c1c4SWadim Egorov serial2 = &main_uart0; 24*3443c1c4SWadim Egorov serial3 = &main_uart1; 25*3443c1c4SWadim Egorov mmc1 = &sdhci1; 26*3443c1c4SWadim Egorov usb0 = &usb0; 27*3443c1c4SWadim Egorov usb1 = &usb1; 28*3443c1c4SWadim Egorov ethernet1 = &cpsw_port2; 29*3443c1c4SWadim Egorov }; 30*3443c1c4SWadim Egorov 31*3443c1c4SWadim Egorov can_tc1: can-phy0 { 32*3443c1c4SWadim Egorov compatible = "ti,tcan1042"; 33*3443c1c4SWadim Egorov #phy-cells = <0>; 34*3443c1c4SWadim Egorov max-bitrate = <5000000>; 35*3443c1c4SWadim Egorov standby-gpios = <&gpio_exp 1 GPIO_ACTIVE_HIGH>; 36*3443c1c4SWadim Egorov }; 37*3443c1c4SWadim Egorov 38*3443c1c4SWadim Egorov keys { 39*3443c1c4SWadim Egorov compatible = "gpio-keys"; 40*3443c1c4SWadim Egorov autorepeat; 41*3443c1c4SWadim Egorov pinctrl-names = "default"; 42*3443c1c4SWadim Egorov pinctrl-0 = <&gpio_keys_pins_default>; 43*3443c1c4SWadim Egorov 44*3443c1c4SWadim Egorov key-home { 45*3443c1c4SWadim Egorov label = "home"; 46*3443c1c4SWadim Egorov linux,code = <KEY_HOME>; 47*3443c1c4SWadim Egorov gpios = <&main_gpio1 23 GPIO_ACTIVE_HIGH>; 48*3443c1c4SWadim Egorov }; 49*3443c1c4SWadim Egorov 50*3443c1c4SWadim Egorov key-menu { 51*3443c1c4SWadim Egorov label = "menu"; 52*3443c1c4SWadim Egorov linux,code = <KEY_MENU>; 53*3443c1c4SWadim Egorov gpios = <&gpio_exp 4 GPIO_ACTIVE_HIGH>; 54*3443c1c4SWadim Egorov }; 55*3443c1c4SWadim Egorov }; 56*3443c1c4SWadim Egorov 57*3443c1c4SWadim Egorov leds { 58*3443c1c4SWadim Egorov compatible = "gpio-leds"; 59*3443c1c4SWadim Egorov pinctrl-names = "default"; 60*3443c1c4SWadim Egorov pinctrl-0 = <&leds_pins_default>, <&user_leds_pins_default>; 61*3443c1c4SWadim Egorov 62*3443c1c4SWadim Egorov led-1 { 63*3443c1c4SWadim Egorov gpios = <&main_gpio0 32 GPIO_ACTIVE_HIGH>; 64*3443c1c4SWadim Egorov linux,default-trigger = "mmc0"; 65*3443c1c4SWadim Egorov }; 66*3443c1c4SWadim Egorov 67*3443c1c4SWadim Egorov led-2 { 68*3443c1c4SWadim Egorov gpios = <&gpio_exp 2 GPIO_ACTIVE_HIGH>; 69*3443c1c4SWadim Egorov linux,default-trigger = "mmc1"; 70*3443c1c4SWadim Egorov }; 71*3443c1c4SWadim Egorov }; 72*3443c1c4SWadim Egorov 73*3443c1c4SWadim Egorov vcc_3v3_mmc: regulator-vcc-3v3-mmc { 74*3443c1c4SWadim Egorov compatible = "regulator-fixed"; 75*3443c1c4SWadim Egorov regulator-name = "VCC_3V3_MMC"; 76*3443c1c4SWadim Egorov regulator-min-microvolt = <3300000>; 77*3443c1c4SWadim Egorov regulator-max-microvolt = <3300000>; 78*3443c1c4SWadim Egorov regulator-always-on; 79*3443c1c4SWadim Egorov regulator-boot-on; 80*3443c1c4SWadim Egorov }; 81*3443c1c4SWadim Egorov}; 82*3443c1c4SWadim Egorov 83*3443c1c4SWadim Egorov&main_pmx0 { 84*3443c1c4SWadim Egorov gpio_keys_pins_default: gpio-keys-pins-default { 85*3443c1c4SWadim Egorov pinctrl-single,pins = < 86*3443c1c4SWadim Egorov AM62X_IOPAD(0x1d4, PIN_INPUT, 7) /* (B15) UART0_RTSn.GPIO1_23 */ 87*3443c1c4SWadim Egorov >; 88*3443c1c4SWadim Egorov }; 89*3443c1c4SWadim Egorov 90*3443c1c4SWadim Egorov gpio_exp_int_pins_default: gpio-exp-int-pins-default { 91*3443c1c4SWadim Egorov pinctrl-single,pins = < 92*3443c1c4SWadim Egorov AM62X_IOPAD(0x244, PIN_INPUT, 7) /* (C17) MMC1_SDWP.GPIO1_49 */ 93*3443c1c4SWadim Egorov >; 94*3443c1c4SWadim Egorov }; 95*3443c1c4SWadim Egorov 96*3443c1c4SWadim Egorov main_i2c1_pins_default: main-i2c1-pins-default { 97*3443c1c4SWadim Egorov pinctrl-single,pins = < 98*3443c1c4SWadim Egorov AM62X_IOPAD(0x1e8, PIN_INPUT_PULLUP, 0) /* (B17) I2C1_SCL */ 99*3443c1c4SWadim Egorov AM62X_IOPAD(0x1ec, PIN_INPUT_PULLUP, 0) /* (A17) I2C1_SDA */ 100*3443c1c4SWadim Egorov >; 101*3443c1c4SWadim Egorov }; 102*3443c1c4SWadim Egorov 103*3443c1c4SWadim Egorov main_mcan0_pins_default: main-mcan0-pins-default { 104*3443c1c4SWadim Egorov pinctrl-single,pins = < 105*3443c1c4SWadim Egorov AM62X_IOPAD(0x1dc, PIN_INPUT, 0) /* (E15) MCAN0_RX */ 106*3443c1c4SWadim Egorov AM62X_IOPAD(0x1d8, PIN_OUTPUT, 0) /* (C15) MCAN0_TX */ 107*3443c1c4SWadim Egorov >; 108*3443c1c4SWadim Egorov }; 109*3443c1c4SWadim Egorov 110*3443c1c4SWadim Egorov main_mmc1_pins_default: main-mmc1-pins-default { 111*3443c1c4SWadim Egorov pinctrl-single,pins = < 112*3443c1c4SWadim Egorov AM62X_IOPAD(0x23c, PIN_INPUT_PULLUP, 0) /* (A21) MMC1_CMD */ 113*3443c1c4SWadim Egorov AM62X_IOPAD(0x234, PIN_INPUT_PULLDOWN, 0) /* (B22) MMC1_CLK */ 114*3443c1c4SWadim Egorov AM62X_IOPAD(0x230, PIN_INPUT_PULLUP, 0) /* (A22) MMC1_DAT0 */ 115*3443c1c4SWadim Egorov AM62X_IOPAD(0x22c, PIN_INPUT_PULLUP, 0) /* (B21) MMC1_DAT1 */ 116*3443c1c4SWadim Egorov AM62X_IOPAD(0x228, PIN_INPUT_PULLUP, 0) /* (C21) MMC1_DAT2 */ 117*3443c1c4SWadim Egorov AM62X_IOPAD(0x224, PIN_INPUT_PULLUP, 0) /* (D22) MMC1_DAT3 */ 118*3443c1c4SWadim Egorov AM62X_IOPAD(0x240, PIN_INPUT_PULLUP, 0) /* (D17) MMC1_SDCD */ 119*3443c1c4SWadim Egorov >; 120*3443c1c4SWadim Egorov }; 121*3443c1c4SWadim Egorov 122*3443c1c4SWadim Egorov main_rgmii2_pins_default: main-rgmii2-pins-default { 123*3443c1c4SWadim Egorov pinctrl-single,pins = < 124*3443c1c4SWadim Egorov AM62X_IOPAD(0x184, PIN_INPUT, 0) /* (AE23) RGMII2_RD0 */ 125*3443c1c4SWadim Egorov AM62X_IOPAD(0x188, PIN_INPUT, 0) /* (AB20) RGMII2_RD1 */ 126*3443c1c4SWadim Egorov AM62X_IOPAD(0x18c, PIN_INPUT, 0) /* (AC21) RGMII2_RD2 */ 127*3443c1c4SWadim Egorov AM62X_IOPAD(0x190, PIN_INPUT, 0) /* (AE22) RGMII2_RD3 */ 128*3443c1c4SWadim Egorov AM62X_IOPAD(0x180, PIN_INPUT, 0) /* (AD23) RGMII2_RXC */ 129*3443c1c4SWadim Egorov AM62X_IOPAD(0x17c, PIN_INPUT, 0) /* (AD22) RGMII2_RX_CTL */ 130*3443c1c4SWadim Egorov AM62X_IOPAD(0x16c, PIN_OUTPUT, 0) /* (Y18) RGMII2_TD0 */ 131*3443c1c4SWadim Egorov AM62X_IOPAD(0x170, PIN_OUTPUT, 0) /* (AA18) RGMII2_TD1 */ 132*3443c1c4SWadim Egorov AM62X_IOPAD(0x174, PIN_OUTPUT, 0) /* (AD21) RGMII2_TD2 */ 133*3443c1c4SWadim Egorov AM62X_IOPAD(0x178, PIN_OUTPUT, 0) /* (AC20) RGMII2_TD3 */ 134*3443c1c4SWadim Egorov AM62X_IOPAD(0x168, PIN_OUTPUT, 0) /* (AE21) RGMII2_TXC */ 135*3443c1c4SWadim Egorov AM62X_IOPAD(0x164, PIN_OUTPUT, 0) /* (AA19) RGMII2_TX_CTL */ 136*3443c1c4SWadim Egorov >; 137*3443c1c4SWadim Egorov }; 138*3443c1c4SWadim Egorov 139*3443c1c4SWadim Egorov main_uart0_pins_default: main-uart0-pins-default { 140*3443c1c4SWadim Egorov pinctrl-single,pins = < 141*3443c1c4SWadim Egorov AM62X_IOPAD(0x1c8, PIN_INPUT, 0) /* (D14) UART0_RXD */ 142*3443c1c4SWadim Egorov AM62X_IOPAD(0x1cc, PIN_OUTPUT, 0) /* (E14) UART0_TXD */ 143*3443c1c4SWadim Egorov >; 144*3443c1c4SWadim Egorov }; 145*3443c1c4SWadim Egorov 146*3443c1c4SWadim Egorov main_uart1_pins_default: main-uart1-pins-default { 147*3443c1c4SWadim Egorov pinctrl-single,pins = < 148*3443c1c4SWadim Egorov AM62X_IOPAD(0x194, PIN_INPUT, 2) /* (B19) MCASP0_AXR3.UART1_CTSn */ 149*3443c1c4SWadim Egorov AM62X_IOPAD(0x198, PIN_OUTPUT, 2) /* (A19) MCASP0_AXR2.UART1_RTSn */ 150*3443c1c4SWadim Egorov AM62X_IOPAD(0x1ac, PIN_INPUT, 2) /* (E19) MCASP0_AFSR.UART1_RXD */ 151*3443c1c4SWadim Egorov AM62X_IOPAD(0x1b0, PIN_OUTPUT, 2) /* (A20) MCASP0_ACLKR.UART1_TXD */ 152*3443c1c4SWadim Egorov >; 153*3443c1c4SWadim Egorov }; 154*3443c1c4SWadim Egorov 155*3443c1c4SWadim Egorov main_usb1_pins_default: main-usb1-pins-default { 156*3443c1c4SWadim Egorov pinctrl-single,pins = < 157*3443c1c4SWadim Egorov AM62X_IOPAD(0x258, PIN_OUTPUT, 0) /* (F18) USB1_DRVVBUS */ 158*3443c1c4SWadim Egorov >; 159*3443c1c4SWadim Egorov }; 160*3443c1c4SWadim Egorov 161*3443c1c4SWadim Egorov user_leds_pins_default: user-leds-pins-default { 162*3443c1c4SWadim Egorov pinctrl-single,pins = < 163*3443c1c4SWadim Egorov AM62X_IOPAD(0x084, PIN_OUTPUT, 7) /* (L23) GPMC0_ADVn_ALE.GPIO0_32 */ 164*3443c1c4SWadim Egorov >; 165*3443c1c4SWadim Egorov }; 166*3443c1c4SWadim Egorov}; 167*3443c1c4SWadim Egorov 168*3443c1c4SWadim Egorov&cpsw3g { 169*3443c1c4SWadim Egorov pinctrl-names = "default"; 170*3443c1c4SWadim Egorov pinctrl-0 = <&main_rgmii1_pins_default>, <&main_rgmii2_pins_default>; 171*3443c1c4SWadim Egorov}; 172*3443c1c4SWadim Egorov 173*3443c1c4SWadim Egorov&cpsw_port2 { 174*3443c1c4SWadim Egorov phy-mode = "rgmii-rxid"; 175*3443c1c4SWadim Egorov phy-handle = <&cpsw3g_phy3>; 176*3443c1c4SWadim Egorov}; 177*3443c1c4SWadim Egorov 178*3443c1c4SWadim Egorov&cpsw3g_mdio { 179*3443c1c4SWadim Egorov cpsw3g_phy3: ethernet-phy@3 { 180*3443c1c4SWadim Egorov compatible = "ethernet-phy-id2000.a231", "ethernet-phy-ieee802.3-c22"; 181*3443c1c4SWadim Egorov reg = <3>; 182*3443c1c4SWadim Egorov ti,rx-internal-delay = <DP83867_RGMIIDCTL_2_00_NS>; 183*3443c1c4SWadim Egorov ti,fifo-depth = <DP83867_PHYCR_FIFO_DEPTH_4_B_NIB>; 184*3443c1c4SWadim Egorov }; 185*3443c1c4SWadim Egorov}; 186*3443c1c4SWadim Egorov 187*3443c1c4SWadim Egorov&main_i2c1 { 188*3443c1c4SWadim Egorov pinctrl-names = "default"; 189*3443c1c4SWadim Egorov pinctrl-0 = <&main_i2c1_pins_default>; 190*3443c1c4SWadim Egorov clock-frequency = <400000>; 191*3443c1c4SWadim Egorov status = "okay"; 192*3443c1c4SWadim Egorov 193*3443c1c4SWadim Egorov gpio_exp: gpio-expander@21 { 194*3443c1c4SWadim Egorov pinctrl-names = "default"; 195*3443c1c4SWadim Egorov pinctrl-0 = <&gpio_exp_int_pins_default>; 196*3443c1c4SWadim Egorov compatible = "nxp,pcf8574"; 197*3443c1c4SWadim Egorov reg = <0x21>; 198*3443c1c4SWadim Egorov interrupt-parent = <&main_gpio1>; 199*3443c1c4SWadim Egorov interrupts = <49 0>; 200*3443c1c4SWadim Egorov #gpio-cells = <2>; 201*3443c1c4SWadim Egorov gpio-controller; 202*3443c1c4SWadim Egorov interrupt-controller; 203*3443c1c4SWadim Egorov #interrupt-cells = <2>; 204*3443c1c4SWadim Egorov gpio-line-names = "GPIO0_HDMI_RST", "GPIO1_CAN0_nEN", 205*3443c1c4SWadim Egorov "GPIO2_LED2", "GPIO3_LVDS_GPIO", 206*3443c1c4SWadim Egorov "GPIO4_BUT2", "GPIO5_LVDS_BKLT_EN", 207*3443c1c4SWadim Egorov "GPIO6_ETH1_USER_RESET", "GPIO7_AUDIO_USER_RESET"; 208*3443c1c4SWadim Egorov }; 209*3443c1c4SWadim Egorov 210*3443c1c4SWadim Egorov eeprom@51 { 211*3443c1c4SWadim Egorov compatible = "atmel,24c02"; 212*3443c1c4SWadim Egorov pagesize = <16>; 213*3443c1c4SWadim Egorov reg = <0x51>; 214*3443c1c4SWadim Egorov }; 215*3443c1c4SWadim Egorov}; 216*3443c1c4SWadim Egorov 217*3443c1c4SWadim Egorov&main_mcan0 { 218*3443c1c4SWadim Egorov pinctrl-names = "default"; 219*3443c1c4SWadim Egorov pinctrl-0 = <&main_mcan0_pins_default>; 220*3443c1c4SWadim Egorov phys = <&can_tc1>; 221*3443c1c4SWadim Egorov status = "okay"; 222*3443c1c4SWadim Egorov}; 223*3443c1c4SWadim Egorov 224*3443c1c4SWadim Egorov&main_uart0 { 225*3443c1c4SWadim Egorov pinctrl-names = "default"; 226*3443c1c4SWadim Egorov pinctrl-0 = <&main_uart0_pins_default>; 227*3443c1c4SWadim Egorov status = "okay"; 228*3443c1c4SWadim Egorov}; 229*3443c1c4SWadim Egorov 230*3443c1c4SWadim Egorov&main_uart1 { 231*3443c1c4SWadim Egorov pinctrl-names = "default"; 232*3443c1c4SWadim Egorov pinctrl-0 = <&main_uart1_pins_default>; 233*3443c1c4SWadim Egorov /* Main UART1 may be used by TIFS firmware */ 234*3443c1c4SWadim Egorov status = "okay"; 235*3443c1c4SWadim Egorov}; 236*3443c1c4SWadim Egorov 237*3443c1c4SWadim Egorov&sdhci1 { 238*3443c1c4SWadim Egorov vmmc-supply = <&vcc_3v3_mmc>; 239*3443c1c4SWadim Egorov vqmmc-supply = <&vddshv5_sdio>; 240*3443c1c4SWadim Egorov pinctrl-names = "default"; 241*3443c1c4SWadim Egorov pinctrl-0 = <&main_mmc1_pins_default>; 242*3443c1c4SWadim Egorov ti,driver-strength-ohm = <50>; 243*3443c1c4SWadim Egorov disable-wp; 244*3443c1c4SWadim Egorov no-1-8-v; 245*3443c1c4SWadim Egorov status = "okay"; 246*3443c1c4SWadim Egorov}; 247*3443c1c4SWadim Egorov 248*3443c1c4SWadim Egorov&usbss0 { 249*3443c1c4SWadim Egorov ti,vbus-divider; 250*3443c1c4SWadim Egorov status = "okay"; 251*3443c1c4SWadim Egorov}; 252*3443c1c4SWadim Egorov 253*3443c1c4SWadim Egorov&usbss1 { 254*3443c1c4SWadim Egorov ti,vbus-divider; 255*3443c1c4SWadim Egorov status = "okay"; 256*3443c1c4SWadim Egorov}; 257*3443c1c4SWadim Egorov 258*3443c1c4SWadim Egorov&usb0 { 259*3443c1c4SWadim Egorov dr_mode = "peripheral"; 260*3443c1c4SWadim Egorov}; 261*3443c1c4SWadim Egorov 262*3443c1c4SWadim Egorov&usb1 { 263*3443c1c4SWadim Egorov dr_mode = "host"; 264*3443c1c4SWadim Egorov pinctrl-names = "default"; 265*3443c1c4SWadim Egorov pinctrl-0 = <&main_usb1_pins_default>; 266*3443c1c4SWadim Egorov}; 267