xref: /openbmc/u-boot/drivers/gpio/Kconfig (revision 1fa831c7)
1#
2# GPIO infrastructure and drivers
3#
4
5menu "GPIO Support"
6
7config DM_GPIO
8	bool "Enable Driver Model for GPIO drivers"
9	depends on DM
10	help
11	  Enable driver model for GPIO access. The standard GPIO
12	  interface (gpio_get_value(), etc.) is then implemented by
13	  the GPIO uclass. Drivers provide methods to query the
14	  particular GPIOs that they provide. The uclass interface
15	  is defined in include/asm-generic/gpio.h.
16
17config GPIO_HOG
18	bool "Enable GPIO hog support"
19	depends on DM_GPIO
20	default n
21	help
22	  Enable gpio hog support
23	  The GPIO chip may contain GPIO hog definitions. GPIO hogging
24	  is a mechanism providing automatic GPIO request and config-
25	  uration as part of the gpio-controller's driver probe function.
26
27config SPL_GPIO_HOG
28	bool "Enable GPIO hog support in SPL"
29	depends on SPL_GPIO_SUPPORT
30	default n
31	help
32	  Enable gpio hog support in SPL
33	  The GPIO chip may contain GPIO hog definitions. GPIO hogging
34	  is a mechanism providing automatic GPIO request and config-
35	  uration as part of the gpio-controller's driver probe function.
36
37config ALTERA_PIO
38	bool "Altera PIO driver"
39	depends on DM_GPIO
40	help
41	  Select this to enable PIO for Altera devices. Please find
42	  details on the "Embedded Peripherals IP User Guide" of Altera.
43
44config BCM6345_GPIO
45	bool "BCM6345 GPIO driver"
46	depends on DM_GPIO && ARCH_BMIPS
47	help
48	  This driver supports the GPIO banks on BCM6345 SoCs.
49
50config DWAPB_GPIO
51	bool "DWAPB GPIO driver"
52	depends on DM && DM_GPIO
53	default n
54	help
55	  Support for the Designware APB GPIO driver.
56
57config AT91_GPIO
58	bool "AT91 PIO GPIO driver"
59	depends on DM_GPIO
60	default n
61	help
62	  Say yes here to select AT91 PIO GPIO driver. AT91 PIO
63	  controller manages up to 32 fully programmable input/output
64	  lines. Each I/O line may be dedicated as a general-purpose
65	  I/O or be assigned to a function of an embedded peripheral.
66	  The assignment to a function of an embedded peripheral is
67	  the responsibility of AT91 Pinctrl driver. This driver is
68	  responsible for the general-purpose I/O.
69
70config ATMEL_PIO4
71	bool "ATMEL PIO4 driver"
72	depends on DM_GPIO
73	default n
74	help
75	  Say yes here to support the Atmel PIO4 driver.
76	  The PIO4 is new version of Atmel PIO controller, which manages
77	  up to 128 fully programmable input/output lines. Each I/O line
78	  may be dedicated as a general purpose I/O or be assigned to
79	  a function of an embedded peripheral.
80
81config ASPEED_GPIO
82	bool "Aspeed GPIO Driver"
83	help
84	  This driver supports the Aspeed GPIO controller
85
86config DA8XX_GPIO
87	bool "DA8xx GPIO Driver"
88	help
89	  This driver supports the DA8xx GPIO controller
90
91config INTEL_BROADWELL_GPIO
92	bool "Intel Broadwell GPIO driver"
93	depends on DM
94	help
95	  This driver supports Broadwell U devices which have an expanded
96	  GPIO feature set. The difference is large enough to merit a separate
97	  driver from the common Intel ICH6 driver. It supports a total of
98	  95 GPIOs which can be configured from the device tree.
99
100config INTEL_ICH6_GPIO
101	bool "Intel ICH6 compatible legacy GPIO driver"
102	depends on DM_GPIO
103	help
104	  Say yes here to select Intel ICH6 compatible legacy GPIO driver.
105
106config IMX_RGPIO2P
107	bool "i.MX7ULP RGPIO2P driver"
108	depends on DM
109	default n
110	help
111	  This driver supports i.MX7ULP Rapid GPIO2P controller.
112
113config HSDK_CREG_GPIO
114	bool "HSDK CREG GPIO griver"
115	depends on DM_GPIO
116	default n
117	help
118	  This driver supports CREG GPIOs on Synopsys HSDK SOC.
119
120config LPC32XX_GPIO
121	bool "LPC32XX GPIO driver"
122	depends on DM
123	default n
124	help
125	  Support for the LPC32XX GPIO driver.
126
127config MSCC_SGPIO
128	bool "Microsemi Serial GPIO driver"
129	depends on DM_GPIO && SOC_VCOREIII
130	help
131	  Support for the VCoreIII SoC serial GPIO device. By using a
132          serial interface, the SIO controller significantly extends
133          the number of available GPIOs with a minimum number of
134          additional pins on the device. The primary purpose of the
135          SIO controller is to connect control signals from SFP
136          modules and to act as an LED controller.
137
138config MSM_GPIO
139	bool "Qualcomm GPIO driver"
140	depends on DM_GPIO
141	default n
142	help
143	  Support GPIO controllers on Qualcomm Snapdragon family of SoCs.
144	  This controller have single bank (default name "soc"), every
145	  gpio has it's own set of registers.
146	  Only simple GPIO operations are supported (get/set, change of
147	  direction and checking pin function).
148	  Supported devices:
149	  - APQ8016
150	  - MSM8916
151
152config MXC_GPIO
153	bool "Freescale/NXP MXC GPIO driver"
154	help
155	  Support GPIO controllers on various i.MX platforms
156
157config OMAP_GPIO
158	bool "TI OMAP GPIO driver"
159	depends on ARCH_OMAP2PLUS
160	default y
161	help
162	  Support GPIO controllers on the TI OMAP3/4/5 and related (such as
163	  AM335x/AM43xx/AM57xx/DRA7xx/etc) families of SoCs.
164
165config CMD_PCA953X
166	bool "Enable the pca953x command"
167	help
168	  Deprecated: This should be converted to driver model.
169
170	  This command provides access to a pca953x GPIO device using the
171	  legacy GPIO interface. Several subcommands are provided which mirror
172	  the standard 'gpio' command. It should use that instead.
173
174config PM8916_GPIO
175	bool "Qualcomm PM8916 PMIC GPIO/keypad driver"
176	depends on DM_GPIO && PMIC_PM8916
177	help
178	  Support for GPIO pins and power/reset buttons found on
179	  Qualcomm PM8916 PMIC.
180	  Default name for GPIO bank is "pm8916".
181	  Power and reset buttons are placed in "pm8916_key" bank and
182          have gpio numbers 0 and 1 respectively.
183
184config PCF8575_GPIO
185	bool "PCF8575 I2C GPIO Expander driver"
186	depends on DM_GPIO && DM_I2C
187	help
188	 Support for PCF8575 I2C 16-bit GPIO expander. Most of these
189	 chips are from NXP and TI.
190
191config RCAR_GPIO
192	bool "Renesas RCar GPIO driver"
193	depends on DM_GPIO && ARCH_RMOBILE
194	help
195	  This driver supports the GPIO banks on Renesas RCar SoCs.
196
197config ROCKCHIP_GPIO
198	bool "Rockchip GPIO driver"
199	depends on DM_GPIO
200	help
201	  Support GPIO access on Rockchip SoCs. The GPIOs are arranged into
202	  a number of banks (different for each SoC type) each with 32 GPIOs.
203	  The GPIOs for a device are defined in the device tree with one node
204	  for each bank.
205
206config SANDBOX_GPIO
207	bool "Enable sandbox GPIO driver"
208	depends on SANDBOX && DM && DM_GPIO
209	help
210	  This driver supports some simulated GPIOs which can be adjusted
211	  using 'back door' functions like sandbox_gpio_set_value(). Then the
212	  GPIOs can be inspected through the normal get_get_value()
213	  interface. The purpose of this is to allow GPIOs to be used as
214	  normal in sandbox, perhaps with test code actually driving the
215	  behaviour of those GPIOs.
216
217config SANDBOX_GPIO_COUNT
218	int "Number of sandbox GPIOs"
219	depends on SANDBOX_GPIO
220	default 128
221	help
222	  The sandbox driver can support any number of GPIOs. Generally these
223	  are specified using the device tree. But you can also have a number
224	  of 'anonymous' GPIOs that do not belong to any device or bank.
225	  Select a suitable value depending on your needs.
226
227config XILINX_GPIO
228	bool "Xilinx GPIO driver"
229	depends on DM_GPIO
230	help
231	  This config enable the Xilinx GPIO driver for Microblaze.
232
233config CMD_TCA642X
234	bool "tca642x - Command to access tca642x state"
235	help
236	  DEPRECATED - This needs conversion to driver model
237
238	  This provides a way to looking at the pin state of this device.
239	  This mirrors the 'gpio' command and that should be used in preference
240	  to custom code.
241
242config TEGRA_GPIO
243	bool "Tegra20..210 GPIO driver"
244	depends on DM_GPIO
245	help
246	  Support for the GPIO controller contained in NVIDIA Tegra20 through
247	  Tegra210.
248
249config TEGRA186_GPIO
250	bool "Tegra186 GPIO driver"
251	depends on DM_GPIO
252	help
253	  Support for the GPIO controller contained in NVIDIA Tegra186. This
254	  covers both the "main" and "AON" controller instances, even though
255	  they have slightly different register layout.
256
257config GPIO_UNIPHIER
258	bool "UniPhier GPIO"
259	depends on ARCH_UNIPHIER
260	help
261	  Say yes here to support UniPhier GPIOs.
262
263config VYBRID_GPIO
264	bool "Vybrid GPIO driver"
265	depends on DM
266	default n
267	help
268	  Say yes here to support Vybrid vf610 GPIOs.
269
270config PIC32_GPIO
271	bool "Microchip PIC32 GPIO driver"
272	depends on DM_GPIO && MACH_PIC32
273	default y
274	help
275	  Say yes here to support Microchip PIC32 GPIOs.
276
277config STM32F7_GPIO
278	bool "ST STM32 GPIO driver"
279	depends on DM_GPIO && (STM32 || ARCH_STM32MP)
280	default y
281	help
282	  Device model driver support for STM32 GPIO controller. It should be
283	  usable on many stm32 families like stm32f4 & stm32H7.
284	  Tested on STM32F7.
285
286config MVEBU_GPIO
287	bool "Marvell MVEBU GPIO driver"
288	depends on DM_GPIO && ARCH_MVEBU
289	default y
290	help
291	  Say yes here to support Marvell MVEBU (Armada XP/38x) GPIOs.
292
293config ZYNQ_GPIO
294	bool "Zynq GPIO driver"
295	depends on DM_GPIO && (ARCH_ZYNQ || ARCH_ZYNQMP)
296	default y
297	help
298	  Supports GPIO access on Zynq SoC.
299
300config DM_74X164
301	bool "74x164 serial-in/parallel-out 8-bits shift register"
302	depends on DM_GPIO
303	help
304	  Driver for 74x164 compatible serial-in/parallel-out 8-outputs
305	  shift registers, such as 74lv165, 74hc595.
306	  This driver can be used to provide access to more gpio outputs.
307
308config DM_PCA953X
309	bool "PCA95[357]x, PCA9698, TCA64xx, and MAX7310 I/O ports"
310	depends on DM_GPIO
311	help
312	  Say yes here to provide access to several register-oriented
313	  SMBus I/O expanders, made mostly by NXP or TI.  Compatible
314	  models include:
315
316	  4 bits:	pca9536, pca9537
317
318	  8 bits:	max7310, max7315, pca6107, pca9534, pca9538, pca9554,
319			pca9556, pca9557, pca9574, tca6408, xra1202
320
321	  16 bits:	max7312, max7313, pca9535, pca9539, pca9555, pca9575,
322			tca6416
323
324	  24 bits:	tca6424
325
326	  40 bits:	pca9505, pca9698
327
328	  Now, max 24 bits chips and PCA953X compatible chips are
329	  supported
330
331config SPL_DM_PCA953X
332	bool "PCA95[357]x, PCA9698, TCA64xx, and MAX7310 I/O ports in SPL"
333	depends on DM_GPIO
334	help
335	  Say yes here to provide access to several register-oriented
336	  SMBus I/O expanders, made mostly by NXP or TI.  Compatible
337	  models include:
338
339	  4 bits:	pca9536, pca9537
340
341	  8 bits:	max7310, max7315, pca6107, pca9534, pca9538, pca9554,
342			pca9556, pca9557, pca9574, tca6408, xra1202
343
344	  16 bits:	max7312, max7313, pca9535, pca9539, pca9555, pca9575,
345			tca6416
346
347	  24 bits:	tca6424
348
349	  40 bits:	pca9505, pca9698
350
351	  Now, max 24 bits chips and PCA953X compatible chips are
352	  supported
353
354config MPC8XXX_GPIO
355	bool "Freescale MPC8XXX GPIO driver"
356	depends on DM_GPIO
357	help
358	  This driver supports the built-in GPIO controller of MPC8XXX CPUs.
359	  Each GPIO bank is identified by its own entry in the device tree,
360	  i.e.
361
362	  gpio-controller@fc00 {
363		#gpio-cells = <2>;
364		compatible = "fsl,pq3-gpio";
365		reg = <0xfc00 0x100>
366	  }
367
368	  By default, each bank is assumed to have 32 GPIOs, but the ngpios
369	  setting is honored, so the number of GPIOs for each bank is
370	  configurable to match the actual GPIO count of the SoC (e.g. the
371	  32/32/23 banks of the P1022 SoC).
372
373	  Aside from the standard functions of input/output mode, and output
374	  value setting, the open-drain feature, which can configure individual
375	  GPIOs to work as open-drain outputs, is supported.
376
377config MT7621_GPIO
378	bool "MediaTek MT7621 GPIO driver"
379	depends on DM_GPIO && ARCH_MT7620
380	default y
381	help
382	  Say yes here to support MediaTek MT7621 compatible GPIOs.
383
384endmenu
385