summaryrefslogtreecommitdiff
path: root/include/dt-bindings/pinctrl/pinctrl-cv18xx.h
blob: bc92ad1067ec754f8926575e24079234e4eba1d0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/* SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause */
/*
 * Copyright (C) 2023 Sophgo Ltd.
 *
 * Author: Inochi Amaoto <inochiama@outlook.com>
 */

#ifndef _DT_BINDINGS_PINCTRL_CV18XX_H
#define _DT_BINDINGS_PINCTRL_CV18XX_H

#define PIN_MUX_INVALD				0xff

#define PINMUX2(pin, mux, mux2)	\
	(((pin) & 0xffff) | (((mux) & 0xff) << 16) | (((mux2) & 0xff) << 24))

#define PINMUX(pin, mux) \
	PINMUX2(pin, mux, PIN_MUX_INVALD)

#endif /* _DT_BINDINGS_PINCTRL_CV18XX_H */