Zephyr API Documentation  3.5.0
A Scalable Open Source RTOS
3.5.0
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
pinctrl-rcar-common.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2021 IoT.bzh
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
7#ifndef ZEPHYR_INCLUDE_DT_BINDINGS_PINCTRL_RENESAS_PINCTRL_RCAR_COMMON_H_
8#define ZEPHYR_INCLUDE_DT_BINDINGS_PINCTRL_RENESAS_PINCTRL_RCAR_COMMON_H_
9
23#define IPSR(bank, shift, func) (((bank) << 10U) | ((shift) << 4U) | (func))
24
25/* Arbitrary number to encode non capable gpio pin */
26#define PIN_NOGPSR_START 1024U
27
34#define RCAR_GP_PIN(bank, pin) (((bank) * 32U) + (pin))
35
41#define RCAR_NOGP_PIN(pin) (PIN_NOGPSR_START + pin)
42
43#endif /* ZEPHYR_INCLUDE_DT_BINDINGS_PINCTRL_RENESAS_PINCTRL_RCAR_COMMON_H_ */