xref: /linux/drivers/pinctrl/mediatek/Kconfig (revision eafd95ea74846eda3e3eac6b2bb7f34619d8a6f8)
1# SPDX-License-Identifier: GPL-2.0-only
2menu "MediaTek pinctrl drivers"
3	depends on ARCH_MEDIATEK || ARCH_AIROHA || RALINK || 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
21config PINCTRL_MTK_V2
22	tristate
23
24config PINCTRL_MTK_MTMIPS
25	bool
26	depends on RALINK
27	select PINMUX
28	select GENERIC_PINCONF
29
30config PINCTRL_MTK_MOORE
31	bool
32	depends on OF
33	select GENERIC_PINCONF
34	select GENERIC_PINCTRL_GROUPS
35	select GENERIC_PINMUX_FUNCTIONS
36	select GPIOLIB
37	select EINT_MTK
38	select PINCTRL_MTK_V2
39
40config PINCTRL_MTK_PARIS
41	tristate
42	depends on OF
43	select PINMUX
44	select GENERIC_PINCONF
45	select GPIOLIB
46	select EINT_MTK
47	select PINCTRL_MTK_V2
48
49# For MIPS SoCs
50config PINCTRL_MT7620
51	bool "MediaTek MT7620 pin control"
52	depends on SOC_MT7620 || COMPILE_TEST
53	depends on RALINK
54	default SOC_MT7620
55	select PINCTRL_MTK_MTMIPS
56
57config PINCTRL_MT7621
58	bool "MediaTek MT7621 pin control"
59	depends on SOC_MT7621 || COMPILE_TEST
60	depends on RALINK
61	default SOC_MT7621
62	select PINCTRL_MTK_MTMIPS
63
64config PINCTRL_MT76X8
65	bool "MediaTek MT76X8 pin control"
66	depends on SOC_MT7620 || COMPILE_TEST
67	depends on RALINK
68	default SOC_MT7620
69	select PINCTRL_MTK_MTMIPS
70
71config PINCTRL_RT2880
72	bool "Ralink RT2880 pin control"
73	depends on SOC_RT288X || COMPILE_TEST
74	depends on RALINK
75	default SOC_RT288X
76	select PINCTRL_MTK_MTMIPS
77
78config PINCTRL_RT305X
79	bool "Ralink RT305X pin control"
80	depends on SOC_RT305X || COMPILE_TEST
81	depends on RALINK
82	default SOC_RT305X
83	select PINCTRL_MTK_MTMIPS
84
85config PINCTRL_RT3883
86	bool "Ralink RT3883 pin control"
87	depends on SOC_RT3883 || COMPILE_TEST
88	depends on RALINK
89	default SOC_RT3883
90	select PINCTRL_MTK_MTMIPS
91
92# For ARMv7 SoCs
93config PINCTRL_MT2701
94	bool "MediaTek MT2701 pin control"
95	depends on MACH_MT7623 || MACH_MT2701 || COMPILE_TEST
96	depends on OF
97	default MACH_MT2701
98	select PINCTRL_MTK
99
100config PINCTRL_MT7623
101	bool "MediaTek MT7623 pin control with generic binding"
102	depends on MACH_MT7623 || COMPILE_TEST
103	depends on OF
104	default MACH_MT7623
105	select PINCTRL_MTK_MOORE
106
107config PINCTRL_MT7629
108	bool "MediaTek MT7629 pin control"
109	depends on MACH_MT7629 || COMPILE_TEST
110	depends on OF
111	default MACH_MT7629
112	select PINCTRL_MTK_MOORE
113
114config PINCTRL_MT8135
115	bool "MediaTek MT8135 pin control"
116	depends on MACH_MT8135 || COMPILE_TEST
117	depends on OF
118	default MACH_MT8135
119	select PINCTRL_MTK
120
121config PINCTRL_MT8127
122	bool "MediaTek MT8127 pin control"
123	depends on MACH_MT8127 || COMPILE_TEST
124	depends on OF
125	default MACH_MT8127
126	select PINCTRL_MTK
127
128# For ARMv8 SoCs
129config PINCTRL_AIROHA
130	tristate "Airoha EN7581 pin control"
131	depends on OF
132	depends on ARM64 || COMPILE_TEST
133	select PINMUX
134	select GENERIC_PINCONF
135	select GENERIC_PINCTRL_GROUPS
136	select GENERIC_PINMUX_FUNCTIONS
137	select GPIOLIB
138	select GPIOLIB_IRQCHIP
139	select REGMAP_MMIO
140	help
141	  Say yes here to support pin controller and gpio driver
142	  on Airoha EN7581 SoC.
143
144config PINCTRL_MT2712
145	bool "MediaTek MT2712 pin control"
146	depends on OF
147	depends on ARM64 || COMPILE_TEST
148	default ARM64 && ARCH_MEDIATEK
149	select PINCTRL_MTK
150
151config PINCTRL_MT6765
152	tristate "MediaTek MT6765 pin control"
153	depends on OF
154	depends on ARM64 || COMPILE_TEST
155	default ARM64 && ARCH_MEDIATEK
156	select PINCTRL_MTK_PARIS
157
158config PINCTRL_MT6779
159	tristate "MediaTek MT6779 pin control"
160	depends on OF
161	depends on ARM64 || COMPILE_TEST
162	default ARM64 && ARCH_MEDIATEK
163	select PINCTRL_MTK_PARIS
164	help
165	  Say yes here to support pin controller and gpio driver
166	  on MediaTek MT6779 SoC.
167	  In MTK platform, we support virtual gpio and use it to
168	  map specific eint which doesn't have real gpio pin.
169
170config PINCTRL_MT6795
171	bool "MediaTek MT6795 pin control"
172	depends on OF
173	depends on ARM64 || COMPILE_TEST
174	default ARM64 && ARCH_MEDIATEK
175	select PINCTRL_MTK_PARIS
176
177config PINCTRL_MT6797
178	bool "MediaTek MT6797 pin control"
179	depends on OF
180	depends on ARM64 || COMPILE_TEST
181	default ARM64 && ARCH_MEDIATEK
182	select PINCTRL_MTK_PARIS
183
184config PINCTRL_MT6893
185	bool "MediaTek Dimensity MT6893 pin control"
186	depends on OF
187	depends on ARM64 || COMPILE_TEST
188	default ARM64 && ARCH_MEDIATEK
189	select PINCTRL_MTK_PARIS
190	help
191	  Say yes here to support pin controller and gpio driver
192	  on the MediaTek Dimensity 1200 MT6893 Smartphone SoC.
193
194config PINCTRL_MT7622
195	bool "MediaTek MT7622 pin control"
196	depends on OF
197	depends on ARM64 || COMPILE_TEST
198	default ARM64 && ARCH_MEDIATEK
199	select PINCTRL_MTK_MOORE
200
201config PINCTRL_MT7981
202	bool "MediaTek MT7981 pin control"
203	depends on OF
204	depends on ARM64 || COMPILE_TEST
205	default ARM64 && ARCH_MEDIATEK
206	select PINCTRL_MTK_MOORE
207
208config PINCTRL_MT7986
209	bool "MediaTek MT7986 pin control"
210	depends on OF
211	depends on ARM64 || COMPILE_TEST
212	default ARM64 && ARCH_MEDIATEK
213	select PINCTRL_MTK_MOORE
214
215config PINCTRL_MT7988
216	bool "Mediatek MT7988 pin control"
217	depends on OF
218	depends on ARM64 || COMPILE_TEST
219	default ARM64 && ARCH_MEDIATEK
220	select PINCTRL_MTK_MOORE
221
222config PINCTRL_MT8167
223	bool "MediaTek MT8167 pin control"
224	depends on OF
225	depends on ARM64 || COMPILE_TEST
226	default ARM64 && ARCH_MEDIATEK
227	select PINCTRL_MTK
228
229config PINCTRL_MT8173
230	bool "MediaTek MT8173 pin control"
231	depends on OF
232	depends on ARM64 || COMPILE_TEST
233	default ARM64 && ARCH_MEDIATEK
234	select PINCTRL_MTK
235
236config PINCTRL_MT8183
237	bool "MediaTek MT8183 pin control"
238	depends on OF
239	depends on ARM64 || COMPILE_TEST
240	default ARM64 && ARCH_MEDIATEK
241	select PINCTRL_MTK_PARIS
242
243config PINCTRL_MT8186
244	bool "MediaTek MT8186 pin control"
245	depends on OF
246	depends on ARM64 || COMPILE_TEST
247	default ARM64 && ARCH_MEDIATEK
248	select PINCTRL_MTK_PARIS
249
250config PINCTRL_MT8188
251	bool "MediaTek MT8188 pin control"
252	depends on OF
253	depends on ARM64 || COMPILE_TEST
254	default ARM64 && ARCH_MEDIATEK
255	select PINCTRL_MTK_PARIS
256	help
257	  Say yes here to support pin controller and gpio driver
258	  on MediaTek MT8188 SoC.
259	  In MTK platform, we support virtual gpio and use it to
260	  map specific eint which doesn't have real gpio pin.
261
262config PINCTRL_MT8192
263	bool "MediaTek MT8192 pin control"
264	depends on OF
265	depends on ARM64 || COMPILE_TEST
266	default ARM64 && ARCH_MEDIATEK
267	select PINCTRL_MTK_PARIS
268
269config PINCTRL_MT8195
270	bool "MediaTek MT8195 pin control"
271	depends on OF
272	depends on ARM64 || COMPILE_TEST
273	default ARM64 && ARCH_MEDIATEK
274	select PINCTRL_MTK_PARIS
275
276config PINCTRL_MT8196
277	bool "MediaTek MT8196 pin control"
278	depends on OF
279	depends on ARM64 || COMPILE_TEST
280	default ARM64 && ARCH_MEDIATEK
281	select PINCTRL_MTK_PARIS
282	help
283	  Say yes here to support pin controller and gpio driver
284	  on MediaTek MT8196 SoC.
285	  In MTK platform, we support virtual gpio and use it to
286	  map specific eint which doesn't have real gpio pin.
287
288config PINCTRL_MT8365
289	bool "MediaTek MT8365 pin control"
290	depends on OF
291	depends on ARM64 || COMPILE_TEST
292	default ARM64 && ARCH_MEDIATEK
293	select PINCTRL_MTK
294
295config PINCTRL_MT8516
296	bool "MediaTek MT8516 pin control"
297	depends on OF
298	depends on ARM64 || COMPILE_TEST
299	default ARM64 && ARCH_MEDIATEK
300	select PINCTRL_MTK
301
302# For PMIC
303config PINCTRL_MT6397
304	bool "MediaTek MT6397 pin control"
305	depends on MFD_MT6397 || COMPILE_TEST
306	depends on OF
307	default MFD_MT6397
308	select PINCTRL_MTK
309
310endmenu
311