// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) /* * Device Tree Source for the RZ/T2H EVK board * * Copyright (C) 2025 Renesas Electronics Corp. */ /dts-v1/; #include "r9a09g077m44.dtsi" /* * SD0 can be connected to either eMMC (IC49) or SD card slot CN31 * Lets by default enable the eMMC, note we need the below SW settings * for eMMC. * SW2[1] = ON; SW2[2] = ON * * To enable SD card and disable eMMC on SDHI0 disable the below macro * and set the below switch setting: * SW2[1] = OFF; SW2[2] = ON */ #define SD0_EMMC 1 #define SD0_SD (!SD0_EMMC) /* * P17_4 = SD1_CD; SW2[3] = ON * P08_5 = SD1_PWEN; SW2[3] = ON * P08_6 = SD1_IOVS; SW2[3] = ON; SW5[3] = OFF; SW5[4] = ON */ #define SD1_MICRO_SD 1 /* * USB Pin Configuration: * * This board is equipped with three USB connectors: Type-A (CN80), Mini-B * (CN79), and Micro-AB (CN33). The RZ/T2H SoC has a single USB channel, so * either the USB host interface or the USB function interface can be used, * but not both simultaneously when using the CN79 and CN80 connectors. * * By default, the Type-A (CN80) and Mini-B (CN79) connectors are enabled. * Configure the switches as follows: * - P00_0 - P00_2 (control signals for USB power supply): SW1[5] = ON * - USB_VBUSIN (used for USB function): SW7[7] = OFF; SW7[8] = ON * - USB_VBUSEN (used for USB_HF_VBUSEN): SW7[9] = OFF; SW7[10] = ON * * To enable the Micro-AB (CN33) USB OTG connector, set the following macro * to 1 and configure the switches as follows: * - P00_0 - P00_2 (control signals for USB power supply): SW1[5] = ON * - USB_VBUSIN (used for USB OTG): SW7[7] = ON; SW7[8] = OFF * - USB_VBUSEN (used for USB_OTG_VBUSEN): SW7[9] = ON; SW7[10] = OFF */ #define USB_OTG 0 #include "rzt2h-n2h-evk-common.dtsi" / { model = "Renesas RZ/T2H EVK Board based on r9a09g077m44"; compatible = "renesas,rzt2h-evk", "renesas,r9a09g077m44", "renesas,r9a09g077"; leds { compatible = "gpio-leds"; led-0 { /* SW8-9: ON, SW8-10: OFF */ gpios = <&pinctrl RZT2H_GPIO(23, 1) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <0>; }; led-1 { /* SW5-1: OFF, SW5-2: ON */ gpios = <&pinctrl RZT2H_GPIO(32, 2) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <1>; }; led-2 { gpios = <&pinctrl RZT2H_GPIO(6, 7) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <2>; }; #if (!SD1_MICRO_SD) led-3 { /* SW2-3: OFF */ gpios = <&pinctrl RZT2H_GPIO(8, 5) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <3>; }; #endif led-4 { /* SW8-3: ON, SW8-4: OFF */ gpios = <&pinctrl RZT2H_GPIO(18, 0) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <4>; }; led-5 { /* SW8-1: ON, SW8-2: OFF */ gpios = <&pinctrl RZT2H_GPIO(18, 1) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <5>; }; led-6 { /* SW5-9: OFF, SW5-10: ON */ gpios = <&pinctrl RZT2H_GPIO(22, 7) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <6>; }; led-7 { /* SW5-7: OFF, SW5-8: ON */ gpios = <&pinctrl RZT2H_GPIO(23, 0) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <7>; }; led-8 { /* SW7-5: OFF, SW7-6: ON */ gpios = <&pinctrl RZT2H_GPIO(23, 5) GPIO_ACTIVE_HIGH>; color = ; function = LED_FUNCTION_DEBUG; function-enumerator = <8>; }; }; }; &i2c0 { pinctrl-0 = <&i2c0_pins>; pinctrl-names = "default"; clock-frequency = <400000>; status = "okay"; }; &i2c1 { pinctrl-0 = <&i2c1_pins>; pinctrl-names = "default"; clock-frequency = <400000>; status = "okay"; }; &mdio1_phy { reset-gpios = <&pinctrl RZT2H_GPIO(32, 3) GPIO_ACTIVE_LOW>; }; &mdio2_phy { /* * PHY2 Reset Configuration: * * SW6[1] OFF; SW6[2] ON; SW6[3] OFF - use pin P17_5 for GMAC_RESETOUT2# */ reset-gpios = <&pinctrl RZT2H_GPIO(17, 5) GPIO_ACTIVE_LOW>; }; &pinctrl { /* * GMAC2 Pin Configuration: * * SW2[6] OFF - connect MDC/MDIO of Ethernet port 2 to GMAC2 * SW2[7] ON - use pins P29_1-P29_7, P30_0-P30_4, and P31_2-P31_5 * for Ethernet port 2 */ gmac2_pins: gmac2-pins { pinmux = , /* ETH2_TXCLK */ , /* ETH2_TXD0 */ , /* ETH2_TXD1 */ , /* ETH2_TXD2 */ , /* ETH2_TXD3 */ , /* ETH2_TXEN */ , /* ETH2_RXCLK */ , /* ETH2_RXD0 */ , /* ETH2_RXD1 */ , /* ETH2_RXD2 */ , /* ETH2_RXD3 */ , /* ETH2_RXDV */ , /* ETH2_TXER */ , /* ETH2_RXER */ , /* ETH2_CRS */ , /* ETH2_COL */ , /* GMAC2_MDC */ , /* GMAC2_MDIO */ ; /* ETH2_REFCLK */ }; /* * GMAC1 Pin Configuration: * * SW2[8] ON - use pins P33_2-P33_7, P34_0-P34_5, P34_7 and * P35_0-P35_2 for Ethernet port 3 */ gmac1_pins: gmac1-pins { pinmux = , /* ETH3_TXCLK */ , /* ETH3_TXD0 */ , /* ETH3_TXD1 */ , /* ETH3_TXD2 */ , /* ETH3_TXD3 */ , /* ETH3_TXEN */ , /* ETH3_RXCLK */ , /* ETH3_RXD0 */ , /* ETH3_RXD1 */ , /* ETH3_RXD2 */ , /* ETH3_RXD3 */ , /* ETH3_RXDV */ , /* ETH3_TXER */ , /* ETH3_RXER */ , /* ETH3_CRS */ , /* ETH3_COL */ , /* GMAC1_MDC */ , /* GMAC1_MDIO */ ; /* ETH3_REFCLK */ }; /* * I2C0 Pin Configuration: * ------------------------ * Signal | Pin | SW6 * -------|---------|-------------- * SCL | P23_3 | 7: ON, 8: OFF * SDA | P23_4 | 9: ON, 10: OFF */ i2c0_pins: i2c0-pins { pinmux = , ; }; i2c1_pins: i2c1-pins { pinmux = , /* SDA */ ; /* SCL */ }; #if USB_OTG usb-exicen-hog { gpio-hog; gpios = ; output-high; line-name = "usb_exicen_a"; }; #endif usb_pins: usb-pins { pinmux = , /* VBUSEN */ ; /* OVRCUR */ }; }; &adc2 { status = "okay"; channel@0 { reg = <0x0>; }; channel@1 { reg = <0x1>; }; channel@2 { reg = <0x2>; }; channel@3 { reg = <0x3>; }; channel@4 { reg = <0x4>; }; channel@5 { reg = <0x5>; }; };