Linux 5.1.15
[linux/fpc-iii.git] / drivers / pinctrl / mediatek / pinctrl-moore.h
blobe1b4b82b9d3db47f238c0d3a5a83ef9ad7553f6b
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3 * Copyright (C) 2017-2018 MediaTek Inc.
5 * Author: Sean Wang <sean.wang@mediatek.com>
7 */
8 #ifndef __PINCTRL_MOORE_H
9 #define __PINCTRL_MOORE_H
11 #include <linux/io.h>
12 #include <linux/init.h>
13 #include <linux/of.h>
14 #include <linux/of_platform.h>
15 #include <linux/platform_device.h>
16 #include <linux/pinctrl/pinctrl.h>
17 #include <linux/pinctrl/pinmux.h>
18 #include <linux/pinctrl/pinconf.h>
19 #include <linux/pinctrl/pinconf-generic.h>
21 #include "../core.h"
22 #include "../pinconf.h"
23 #include "../pinmux.h"
24 #include "mtk-eint.h"
25 #include "pinctrl-mtk-common-v2.h"
27 #define MTK_RANGE(_a) { .range = (_a), .nranges = ARRAY_SIZE(_a), }
29 #define MTK_PIN(_number, _name, _eint_m, _eint_n, _drv_n) { \
30 .number = _number, \
31 .name = _name, \
32 .eint = { \
33 .eint_m = _eint_m, \
34 .eint_n = _eint_n, \
35 }, \
36 .drv_n = _drv_n, \
37 .funcs = NULL, \
40 #define PINCTRL_PIN_GROUP(name, id) \
41 { \
42 name, \
43 id##_pins, \
44 ARRAY_SIZE(id##_pins), \
45 id##_funcs, \
48 int mtk_moore_pinctrl_probe(struct platform_device *pdev,
49 const struct mtk_pin_soc *soc);
51 #endif /* __PINCTRL_MOORE_H */