xref: /openbmc/linux/drivers/pinctrl/mediatek/Kconfig (revision ece68749)
1# SPDX-License-Identifier: GPL-2.0-only
2menu "MediaTek pinctrl drivers"
3	depends on ARCH_MEDIATEK || 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_MT2712
130	bool "MediaTek MT2712 pin control"
131	depends on OF
132	depends on ARM64 || COMPILE_TEST
133	default ARM64 && ARCH_MEDIATEK
134	select PINCTRL_MTK
135
136config PINCTRL_MT6765
137	tristate "MediaTek MT6765 pin control"
138	depends on OF
139	depends on ARM64 || COMPILE_TEST
140	default ARM64 && ARCH_MEDIATEK
141	select PINCTRL_MTK_PARIS
142
143config PINCTRL_MT6779
144	tristate "MediaTek MT6779 pin control"
145	depends on OF
146	depends on ARM64 || COMPILE_TEST
147	default ARM64 && ARCH_MEDIATEK
148	select PINCTRL_MTK_PARIS
149	help
150	  Say yes here to support pin controller and gpio driver
151	  on MediaTek MT6779 SoC.
152	  In MTK platform, we support virtual gpio and use it to
153	  map specific eint which doesn't have real gpio pin.
154
155config PINCTRL_MT6795
156	bool "MediaTek MT6795 pin control"
157	depends on OF
158	depends on ARM64 || COMPILE_TEST
159	default ARM64 && ARCH_MEDIATEK
160	select PINCTRL_MTK_PARIS
161
162config PINCTRL_MT6797
163	bool "MediaTek MT6797 pin control"
164	depends on OF
165	depends on ARM64 || COMPILE_TEST
166	default ARM64 && ARCH_MEDIATEK
167	select PINCTRL_MTK_PARIS
168
169config PINCTRL_MT7622
170	bool "MediaTek MT7622 pin control"
171	depends on OF
172	depends on ARM64 || COMPILE_TEST
173	default ARM64 && ARCH_MEDIATEK
174	select PINCTRL_MTK_MOORE
175
176config PINCTRL_MT7981
177	bool "MediaTek MT7981 pin control"
178	depends on OF
179	depends on ARM64 || COMPILE_TEST
180	default ARM64 && ARCH_MEDIATEK
181	select PINCTRL_MTK_MOORE
182
183config PINCTRL_MT7986
184	bool "MediaTek MT7986 pin control"
185	depends on OF
186	depends on ARM64 || COMPILE_TEST
187	default ARM64 && ARCH_MEDIATEK
188	select PINCTRL_MTK_MOORE
189
190config PINCTRL_MT8167
191	bool "MediaTek MT8167 pin control"
192	depends on OF
193	depends on ARM64 || COMPILE_TEST
194	default ARM64 && ARCH_MEDIATEK
195	select PINCTRL_MTK
196
197config PINCTRL_MT8173
198	bool "MediaTek MT8173 pin control"
199	depends on OF
200	depends on ARM64 || COMPILE_TEST
201	default ARM64 && ARCH_MEDIATEK
202	select PINCTRL_MTK
203
204config PINCTRL_MT8183
205	bool "MediaTek MT8183 pin control"
206	depends on OF
207	depends on ARM64 || COMPILE_TEST
208	default ARM64 && ARCH_MEDIATEK
209	select PINCTRL_MTK_PARIS
210
211config PINCTRL_MT8186
212	bool "MediaTek MT8186 pin control"
213	depends on OF
214	depends on ARM64 || COMPILE_TEST
215	default ARM64 && ARCH_MEDIATEK
216	select PINCTRL_MTK_PARIS
217
218config PINCTRL_MT8188
219	bool "MediaTek MT8188 pin control"
220	depends on OF
221	depends on ARM64 || COMPILE_TEST
222	default ARM64 && ARCH_MEDIATEK
223	select PINCTRL_MTK_PARIS
224	help
225	  Say yes here to support pin controller and gpio driver
226	  on MediaTek MT8188 SoC.
227	  In MTK platform, we support virtual gpio and use it to
228	  map specific eint which doesn't have real gpio pin.
229
230config PINCTRL_MT8192
231	bool "MediaTek MT8192 pin control"
232	depends on OF
233	depends on ARM64 || COMPILE_TEST
234	default ARM64 && ARCH_MEDIATEK
235	select PINCTRL_MTK_PARIS
236
237config PINCTRL_MT8195
238	bool "MediaTek MT8195 pin control"
239	depends on OF
240	depends on ARM64 || COMPILE_TEST
241	default ARM64 && ARCH_MEDIATEK
242	select PINCTRL_MTK_PARIS
243
244config PINCTRL_MT8365
245	bool "MediaTek MT8365 pin control"
246	depends on OF
247	depends on ARM64 || COMPILE_TEST
248	default ARM64 && ARCH_MEDIATEK
249	select PINCTRL_MTK
250
251config PINCTRL_MT8516
252	bool "MediaTek MT8516 pin control"
253	depends on OF
254	depends on ARM64 || COMPILE_TEST
255	default ARM64 && ARCH_MEDIATEK
256	select PINCTRL_MTK
257
258# For PMIC
259config PINCTRL_MT6397
260	bool "MediaTek MT6397 pin control"
261	depends on MFD_MT6397 || COMPILE_TEST
262	depends on OF
263	default MFD_MT6397
264	select PINCTRL_MTK
265
266endmenu
267