xref: /freebsd-src/sys/contrib/device-tree/src/arm64/renesas/rzg2ul-smarc-pinfunction.dtsi (revision aa1a8ff2d6dbc51ef058f46f3db5a8bb77967145)
1d5b0e70fSEmmanuel Vadot// SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
2d5b0e70fSEmmanuel Vadot/*
3d5b0e70fSEmmanuel Vadot * Device Tree Source for the RZ/G2UL SMARC pincontrol parts
4d5b0e70fSEmmanuel Vadot *
5d5b0e70fSEmmanuel Vadot * Copyright (C) 2022 Renesas Electronics Corp.
6d5b0e70fSEmmanuel Vadot */
7d5b0e70fSEmmanuel Vadot
8d5b0e70fSEmmanuel Vadot#include <dt-bindings/gpio/gpio.h>
9d5b0e70fSEmmanuel Vadot#include <dt-bindings/pinctrl/rzg2l-pinctrl.h>
10d5b0e70fSEmmanuel Vadot
11d5b0e70fSEmmanuel Vadot&pinctrl {
12d5b0e70fSEmmanuel Vadot	pinctrl-0 = <&sound_clk_pins>;
13d5b0e70fSEmmanuel Vadot	pinctrl-names = "default";
14d5b0e70fSEmmanuel Vadot
15d5b0e70fSEmmanuel Vadot	can0_pins: can0 {
16d5b0e70fSEmmanuel Vadot		pinmux = <RZG2L_PORT_PINMUX(1, 1, 3)>, /* TX */
17d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(1, 2, 3)>; /* RX */
18d5b0e70fSEmmanuel Vadot	};
19d5b0e70fSEmmanuel Vadot
20d5b0e70fSEmmanuel Vadot#if (SW_ET0_EN_N)
21d5b0e70fSEmmanuel Vadot	can0-stb-hog {
22d5b0e70fSEmmanuel Vadot		gpio-hog;
23d5b0e70fSEmmanuel Vadot		gpios = <RZG2L_GPIO(2, 2) GPIO_ACTIVE_HIGH>;
24d5b0e70fSEmmanuel Vadot		output-low;
25d5b0e70fSEmmanuel Vadot		line-name = "can0_stb";
26d5b0e70fSEmmanuel Vadot	};
27d5b0e70fSEmmanuel Vadot#endif
28d5b0e70fSEmmanuel Vadot
29d5b0e70fSEmmanuel Vadot	can1_pins: can1 {
30d5b0e70fSEmmanuel Vadot		pinmux = <RZG2L_PORT_PINMUX(2, 0, 3)>, /* TX */
31d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(2, 1, 3)>; /* RX */
32d5b0e70fSEmmanuel Vadot	};
33d5b0e70fSEmmanuel Vadot
34d5b0e70fSEmmanuel Vadot#if (SW_ET0_EN_N)
35d5b0e70fSEmmanuel Vadot	can1-stb-hog {
36d5b0e70fSEmmanuel Vadot		gpio-hog;
37d5b0e70fSEmmanuel Vadot		gpios = <RZG2L_GPIO(2, 3) GPIO_ACTIVE_HIGH>;
38d5b0e70fSEmmanuel Vadot		output-low;
39d5b0e70fSEmmanuel Vadot		line-name = "can1_stb";
40d5b0e70fSEmmanuel Vadot	};
41d5b0e70fSEmmanuel Vadot#endif
42d5b0e70fSEmmanuel Vadot
43d5b0e70fSEmmanuel Vadot	i2c0_pins: i2c0 {
44d5b0e70fSEmmanuel Vadot		pins = "RIIC0_SDA", "RIIC0_SCL";
45d5b0e70fSEmmanuel Vadot		input-enable;
46d5b0e70fSEmmanuel Vadot	};
47d5b0e70fSEmmanuel Vadot
48d5b0e70fSEmmanuel Vadot	i2c1_pins: i2c1 {
49d5b0e70fSEmmanuel Vadot		pins = "RIIC1_SDA", "RIIC1_SCL";
50d5b0e70fSEmmanuel Vadot		input-enable;
51d5b0e70fSEmmanuel Vadot	};
52d5b0e70fSEmmanuel Vadot
53*aa1a8ff2SEmmanuel Vadot	mtu3_pins: mtu3 {
54*aa1a8ff2SEmmanuel Vadot		mtu2-pwm {
55*aa1a8ff2SEmmanuel Vadot			pinmux = <RZG2L_PORT_PINMUX(4, 0, 4)>; /* MTIOC2A */
56*aa1a8ff2SEmmanuel Vadot		};
57*aa1a8ff2SEmmanuel Vadot	};
58*aa1a8ff2SEmmanuel Vadot
59d5b0e70fSEmmanuel Vadot	scif0_pins: scif0 {
60d5b0e70fSEmmanuel Vadot		pinmux = <RZG2L_PORT_PINMUX(6, 4, 6)>, /* TxD */
61d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(6, 3, 6)>; /* RxD */
62d5b0e70fSEmmanuel Vadot	};
63d5b0e70fSEmmanuel Vadot
64d5b0e70fSEmmanuel Vadot	sd1-pwr-en-hog {
65d5b0e70fSEmmanuel Vadot		gpio-hog;
66d5b0e70fSEmmanuel Vadot		gpios = <RZG2L_GPIO(0, 3) GPIO_ACTIVE_HIGH>;
67d5b0e70fSEmmanuel Vadot		output-high;
68d5b0e70fSEmmanuel Vadot		line-name = "sd1_pwr_en";
69d5b0e70fSEmmanuel Vadot	};
70d5b0e70fSEmmanuel Vadot
71d5b0e70fSEmmanuel Vadot	sdhi1_pins: sd1 {
72d5b0e70fSEmmanuel Vadot		sd1_data {
73d5b0e70fSEmmanuel Vadot			pins = "SD1_DATA0", "SD1_DATA1", "SD1_DATA2", "SD1_DATA3";
74d5b0e70fSEmmanuel Vadot			power-source = <3300>;
75d5b0e70fSEmmanuel Vadot		};
76d5b0e70fSEmmanuel Vadot
77d5b0e70fSEmmanuel Vadot		sd1_ctrl {
78d5b0e70fSEmmanuel Vadot			pins = "SD1_CLK", "SD1_CMD";
79d5b0e70fSEmmanuel Vadot			power-source = <3300>;
80d5b0e70fSEmmanuel Vadot		};
81d5b0e70fSEmmanuel Vadot
82d5b0e70fSEmmanuel Vadot		sd1_mux {
83d5b0e70fSEmmanuel Vadot			pinmux = <RZG2L_PORT_PINMUX(0, 2, 1)>; /* SD1_CD */
84d5b0e70fSEmmanuel Vadot		};
85d5b0e70fSEmmanuel Vadot	};
86d5b0e70fSEmmanuel Vadot
87d5b0e70fSEmmanuel Vadot	sdhi1_pins_uhs: sd1_uhs {
88d5b0e70fSEmmanuel Vadot		sd1_data_uhs {
89d5b0e70fSEmmanuel Vadot			pins = "SD1_DATA0", "SD1_DATA1", "SD1_DATA2", "SD1_DATA3";
90d5b0e70fSEmmanuel Vadot			power-source = <1800>;
91d5b0e70fSEmmanuel Vadot		};
92d5b0e70fSEmmanuel Vadot
93d5b0e70fSEmmanuel Vadot		sd1_ctrl_uhs {
94d5b0e70fSEmmanuel Vadot			pins = "SD1_CLK", "SD1_CMD";
95d5b0e70fSEmmanuel Vadot			power-source = <1800>;
96d5b0e70fSEmmanuel Vadot		};
97d5b0e70fSEmmanuel Vadot
98d5b0e70fSEmmanuel Vadot		sd1_mux_uhs {
99d5b0e70fSEmmanuel Vadot			pinmux = <RZG2L_PORT_PINMUX(0, 2, 1)>; /* SD1_CD */
100d5b0e70fSEmmanuel Vadot		};
101d5b0e70fSEmmanuel Vadot	};
102d5b0e70fSEmmanuel Vadot
103d5b0e70fSEmmanuel Vadot	sound_clk_pins: sound_clk {
104d5b0e70fSEmmanuel Vadot		pins = "AUDIO_CLK1", "AUDIO_CLK2";
105d5b0e70fSEmmanuel Vadot		input-enable;
106d5b0e70fSEmmanuel Vadot	};
107d5b0e70fSEmmanuel Vadot
1088bab661aSEmmanuel Vadot	spi1_pins: spi1 {
1098bab661aSEmmanuel Vadot		pinmux = <RZG2L_PORT_PINMUX(4, 0, 2)>, /* CK */
1108bab661aSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(4, 1, 2)>, /* MOSI */
1118bab661aSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(4, 2, 2)>, /* MISO */
1128bab661aSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(4, 3, 2)>; /* SSL */
1138bab661aSEmmanuel Vadot	};
1148bab661aSEmmanuel Vadot
115d5b0e70fSEmmanuel Vadot	ssi1_pins: ssi1 {
116d5b0e70fSEmmanuel Vadot		pinmux = <RZG2L_PORT_PINMUX(3, 0, 2)>, /* BCK */
117d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(3, 1, 2)>, /* RCK */
118d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(3, 2, 2)>, /* TXD */
119d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(3, 3, 2)>; /* RXD */
120d5b0e70fSEmmanuel Vadot	};
121d5b0e70fSEmmanuel Vadot
122d5b0e70fSEmmanuel Vadot	usb0_pins: usb0 {
123d5b0e70fSEmmanuel Vadot		pinmux = <RZG2L_PORT_PINMUX(5, 0, 1)>, /* VBUS */
124d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(5, 2, 1)>, /* OVC */
125d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(5, 3, 1)>; /* OTG_ID */
126d5b0e70fSEmmanuel Vadot	};
127d5b0e70fSEmmanuel Vadot
128d5b0e70fSEmmanuel Vadot	usb1_pins: usb1 {
129d5b0e70fSEmmanuel Vadot		pinmux = <RZG2L_PORT_PINMUX(5, 4, 5)>, /* OVC */
130d5b0e70fSEmmanuel Vadot			 <RZG2L_PORT_PINMUX(6, 0, 1)>; /* VBUS */
131d5b0e70fSEmmanuel Vadot	};
132d5b0e70fSEmmanuel Vadot};
133