xref: /netbsd-src/sys/external/gpl2/dts/dist/include/dt-bindings/pinctrl/r7s72100-pinctrl.h (revision bdc22b2e01993381dcefeff2bc9b56ca75a4235c)
1 /*	$NetBSD: r7s72100-pinctrl.h,v 1.1.1.2 2017/11/30 19:40:51 jmcneill Exp $	*/
2 
3 /* SPDX-License-Identifier: GPL-2.0 */
4 /*
5  * Defines macros and constants for Renesas RZ/A1 pin controller pin
6  * muxing functions.
7  */
8 #ifndef __DT_BINDINGS_PINCTRL_RENESAS_RZA1_H
9 #define __DT_BINDINGS_PINCTRL_RENESAS_RZA1_H
10 
11 #define RZA1_PINS_PER_PORT	16
12 
13 /*
14  * Create the pin index from its bank and position numbers and store in
15  * the upper 16 bits the alternate function identifier
16  */
17 #define RZA1_PINMUX(b, p, f)	((b) * RZA1_PINS_PER_PORT + (p) | (f << 16))
18 
19 #endif /* __DT_BINDINGS_PINCTRL_RENESAS_RZA1_H */
20