xref: /openbmc/linux/drivers/pinctrl/mediatek/Kconfig (revision 4a2d80ad)
1# SPDX-License-Identifier: GPL-2.0-only
2menu "MediaTek pinctrl drivers"
3	depends on ARCH_MEDIATEK || COMPILE_TEST
4
5config EINT_MTK
6	tristate "MediaTek External Interrupt Support"
7	depends on PINCTRL_MTK || PINCTRL_MTK_MOORE || PINCTRL_MTK_PARIS || COMPILE_TEST
8	select GPIOLIB
9	select IRQ_DOMAIN
10	default y if PINCTRL_MTK || PINCTRL_MTK_MOORE
11	default PINCTRL_MTK_PARIS
12
13config PINCTRL_MTK
14	bool
15	depends on OF
16	select PINMUX
17	select GENERIC_PINCONF
18	select GPIOLIB
19	select EINT_MTK
20	select OF_GPIO
21
22config PINCTRL_MTK_V2
23	tristate
24
25config PINCTRL_MTK_MOORE
26	bool
27	depends on OF
28	select GENERIC_PINCONF
29	select GENERIC_PINCTRL_GROUPS
30	select GENERIC_PINMUX_FUNCTIONS
31	select GPIOLIB
32	select OF_GPIO
33	select EINT_MTK
34	select PINCTRL_MTK_V2
35
36config PINCTRL_MTK_PARIS
37	tristate
38	depends on OF
39	select PINMUX
40	select GENERIC_PINCONF
41	select GPIOLIB
42	select EINT_MTK
43	select OF_GPIO
44	select PINCTRL_MTK_V2
45
46# For ARMv7 SoCs
47config PINCTRL_MT2701
48	bool "Mediatek MT2701 pin control"
49	depends on MACH_MT7623 || MACH_MT2701 || COMPILE_TEST
50	depends on OF
51	default MACH_MT2701
52	select PINCTRL_MTK
53
54config PINCTRL_MT7623
55	bool "Mediatek MT7623 pin control with generic binding"
56	depends on MACH_MT7623 || COMPILE_TEST
57	depends on OF
58	default MACH_MT7623
59	select PINCTRL_MTK_MOORE
60
61config PINCTRL_MT7629
62	bool "Mediatek MT7629 pin control"
63	depends on MACH_MT7629 || COMPILE_TEST
64	depends on OF
65	default MACH_MT7629
66	select PINCTRL_MTK_MOORE
67
68config PINCTRL_MT8135
69	bool "Mediatek MT8135 pin control"
70	depends on MACH_MT8135 || COMPILE_TEST
71	depends on OF
72	default MACH_MT8135
73	select PINCTRL_MTK
74
75config PINCTRL_MT8127
76	bool "Mediatek MT8127 pin control"
77	depends on MACH_MT8127 || COMPILE_TEST
78	depends on OF
79	default MACH_MT8127
80	select PINCTRL_MTK
81
82# For ARMv8 SoCs
83config PINCTRL_MT2712
84	bool "MediaTek MT2712 pin control"
85	depends on OF
86	depends on ARM64 || COMPILE_TEST
87	default ARM64 && ARCH_MEDIATEK
88	select PINCTRL_MTK
89
90config PINCTRL_MT6765
91	tristate "Mediatek MT6765 pin control"
92	depends on OF
93	depends on ARM64 || COMPILE_TEST
94	default ARM64 && ARCH_MEDIATEK
95	select PINCTRL_MTK_PARIS
96
97config PINCTRL_MT6779
98	tristate "Mediatek MT6779 pin control"
99	depends on OF
100	depends on ARM64 || COMPILE_TEST
101	default ARM64 && ARCH_MEDIATEK
102	select PINCTRL_MTK_PARIS
103	help
104	  Say yes here to support pin controller and gpio driver
105	  on Mediatek MT6779 SoC.
106	  In MTK platform, we support virtual gpio and use it to
107	  map specific eint which doesn't have real gpio pin.
108
109config PINCTRL_MT6795
110	bool "Mediatek MT6795 pin control"
111	depends on OF
112	depends on ARM64 || COMPILE_TEST
113	default ARM64 && ARCH_MEDIATEK
114	select PINCTRL_MTK_PARIS
115
116config PINCTRL_MT6797
117	bool "Mediatek MT6797 pin control"
118	depends on OF
119	depends on ARM64 || COMPILE_TEST
120	default ARM64 && ARCH_MEDIATEK
121	select PINCTRL_MTK_PARIS
122
123config PINCTRL_MT7622
124	bool "MediaTek MT7622 pin control"
125	depends on OF
126	depends on ARM64 || COMPILE_TEST
127	default ARM64 && ARCH_MEDIATEK
128	select PINCTRL_MTK_MOORE
129
130config PINCTRL_MT7981
131	bool "Mediatek MT7981 pin control"
132	depends on OF
133	select PINCTRL_MTK_MOORE
134
135config PINCTRL_MT7986
136	bool "Mediatek MT7986 pin control"
137	depends on OF
138	depends on ARM64 || COMPILE_TEST
139	default ARM64 && ARCH_MEDIATEK
140	select PINCTRL_MTK_MOORE
141
142config PINCTRL_MT8167
143	bool "Mediatek MT8167 pin control"
144	depends on OF
145	depends on ARM64 || COMPILE_TEST
146	default ARM64 && ARCH_MEDIATEK
147	select PINCTRL_MTK
148
149config PINCTRL_MT8173
150	bool "Mediatek MT8173 pin control"
151	depends on OF
152	depends on ARM64 || COMPILE_TEST
153	default ARM64 && ARCH_MEDIATEK
154	select PINCTRL_MTK
155
156config PINCTRL_MT8183
157	bool "Mediatek MT8183 pin control"
158	depends on OF
159	depends on ARM64 || COMPILE_TEST
160	default ARM64 && ARCH_MEDIATEK
161	select PINCTRL_MTK_PARIS
162
163config PINCTRL_MT8186
164	bool "Mediatek MT8186 pin control"
165	depends on OF
166	depends on ARM64 || COMPILE_TEST
167	default ARM64 && ARCH_MEDIATEK
168	select PINCTRL_MTK_PARIS
169
170config PINCTRL_MT8188
171	bool "MediaTek MT8188 pin control"
172	depends on OF
173	depends on ARM64 || COMPILE_TEST
174	default ARM64 && ARCH_MEDIATEK
175	select PINCTRL_MTK_PARIS
176	help
177	  Say yes here to support pin controller and gpio driver
178	  on MediaTek MT8188 SoC.
179	  In MTK platform, we support virtual gpio and use it to
180	  map specific eint which doesn't have real gpio pin.
181
182config PINCTRL_MT8192
183	bool "Mediatek MT8192 pin control"
184	depends on OF
185	depends on ARM64 || COMPILE_TEST
186	default ARM64 && ARCH_MEDIATEK
187	select PINCTRL_MTK_PARIS
188
189config PINCTRL_MT8195
190	bool "Mediatek MT8195 pin control"
191	depends on OF
192	depends on ARM64 || COMPILE_TEST
193	default ARM64 && ARCH_MEDIATEK
194	select PINCTRL_MTK_PARIS
195
196config PINCTRL_MT8365
197	bool "Mediatek MT8365 pin control"
198	depends on OF
199	depends on ARM64 || COMPILE_TEST
200	default ARM64 && ARCH_MEDIATEK
201	select PINCTRL_MTK
202
203config PINCTRL_MT8516
204	bool "Mediatek MT8516 pin control"
205	depends on OF
206	depends on ARM64 || COMPILE_TEST
207	default ARM64 && ARCH_MEDIATEK
208	select PINCTRL_MTK
209
210# For PMIC
211config PINCTRL_MT6397
212	bool "Mediatek MT6397 pin control"
213	depends on MFD_MT6397 || COMPILE_TEST
214	depends on OF
215	default MFD_MT6397
216	select PINCTRL_MTK
217
218endmenu
219