brintos

brintos / linux-shallow public Read only

0
0
Text · 1.1 KiB · 8736ce0 Raw
48 lines · c
1/* SPDX-License-Identifier: GPL-2.0 */2/*3 * Defines macros and constants for Renesas RZ/A2 pin controller pin4 * muxing functions.5 */6#ifndef __DT_BINDINGS_PINCTRL_RENESAS_RZA2_H7#define __DT_BINDINGS_PINCTRL_RENESAS_RZA2_H8 9#define RZA2_PINS_PER_PORT	810 11/* Port names as labeled in the Hardware Manual */12#define PORT0 013#define PORT1 114#define PORT2 215#define PORT3 316#define PORT4 417#define PORT5 518#define PORT6 619#define PORT7 720#define PORT8 821#define PORT9 922#define PORTA 1023#define PORTB 1124#define PORTC 1225#define PORTD 1326#define PORTE 1427#define PORTF 1528#define PORTG 1629#define PORTH 1730/* No I */31#define PORTJ 1832#define PORTK 1933#define PORTL 2034#define PORTM 21	/* Pins PM_0/1 are labeled JP_0/1 in HW manual */35 36/*37 * Create the pin index from its bank and position numbers and store in38 * the upper 16 bits the alternate function identifier39 */40#define RZA2_PINMUX(b, p, f)	((b) * RZA2_PINS_PER_PORT + (p) | (f << 16))41 42/*43 * Convert a port and pin label to its global pin index44 */45#define RZA2_PIN(port, pin)	((port) * RZA2_PINS_PER_PORT + (pin))46 47#endif /* __DT_BINDINGS_PINCTRL_RENESAS_RZA2_H */48