xref: /linux/drivers/usb/gadget/udc/Kconfig (revision 950b6662e26e381cf8834b9b78b08261890ee697)
1# SPDX-License-Identifier: GPL-2.0
2#
3# USB Gadget support on a system involves
4#    (a) a peripheral controller, and
5#    (b) the gadget driver using it.
6#
7# NOTE:  Gadget support ** DOES NOT ** depend on host-side CONFIG_USB !!
8#
9#  - Host systems (like PCs) need CONFIG_USB (with "A" jacks).
10#  - Peripherals (like PDAs) need CONFIG_USB_GADGET (with "B" jacks).
11#  - Some systems have both kinds of controllers.
12#
13# With help from a special transceiver and a "Mini-AB" jack, systems with
14# both kinds of controller can also support "USB On-the-Go" (CONFIG_USB_OTG).
15#
16
17#
18# USB Peripheral Controller Support
19#
20# The order here is alphabetical, except that integrated controllers go
21# before discrete ones so they will be the initial/default value:
22#   - integrated/SOC controllers first
23#   - licensed IP used in both SOC and discrete versions
24#   - discrete ones (including all PCI-only controllers)
25#   - debug/dummy gadget+hcd is last.
26#
27menu "USB Peripheral Controller"
28
29#
30# Integrated controllers
31#
32
33config USB_AT91
34	tristate "Atmel AT91 USB Device Port"
35	depends on ARCH_AT91
36	depends on OF
37	help
38	   Many Atmel AT91 processors (such as the AT91RM2000) have a
39	   full speed USB Device Port with support for five configurable
40	   endpoints (plus endpoint zero).
41
42	   Say "y" to link the driver statically, or "m" to build a
43	   dynamically linked module called "at91_udc" and force all
44	   gadget drivers to also be dynamically linked.
45
46config USB_LPC32XX
47	tristate "LPC32XX USB Peripheral Controller"
48	depends on ARCH_LPC32XX || COMPILE_TEST
49	depends on I2C
50	select USB_ISP1301
51	help
52	   This option selects the USB device controller in the LPC32xx SoC.
53
54	   Say "y" to link the driver statically, or "m" to build a
55	   dynamically linked module called "lpc32xx_udc" and force all
56	   gadget drivers to also be dynamically linked.
57
58config USB_ATMEL_USBA
59	tristate "Atmel USBA"
60	depends on ARCH_AT91
61	help
62	  USBA is the integrated high-speed USB Device controller on some
63	  AT91SAM9 and AT91CAP9 processors from Atmel.
64
65	  The fifo_mode parameter is used to select endpoint allocation mode.
66	  fifo_mode = 0 is used to let the driver autoconfigure the endpoints.
67	  In this case, for ep1 2 banks are allocated if it works in isochronous
68	  mode and only 1 bank otherwise. For the rest of the endpoints
69	  only 1 bank is allocated.
70
71	  fifo_mode = 1 is a generic maximum fifo size (1024 bytes) configuration
72	  allowing the usage of ep1 - ep6
73
74	  fifo_mode = 2 is a generic performance maximum fifo size (1024 bytes)
75	  configuration allowing the usage of ep1 - ep3
76
77	  fifo_mode = 3 is a balanced performance configuration allowing the
78	  the usage of ep1 - ep8
79
80config USB_BCM63XX_UDC
81	tristate "Broadcom BCM63xx Peripheral Controller"
82	depends on BCM63XX
83	help
84	   Many Broadcom BCM63xx chipsets (such as the BCM6328) have a
85	   high speed USB Device Port with support for four fixed endpoints
86	   (plus endpoint zero).
87
88	   Say "y" to link the driver statically, or "m" to build a
89	   dynamically linked module called "bcm63xx_udc".
90
91config USB_FSL_USB2
92	tristate "Freescale Highspeed USB DR Peripheral Controller"
93	depends on FSL_SOC
94	help
95	   Some of Freescale PowerPC and i.MX processors have a High Speed
96	   Dual-Role(DR) USB controller, which supports device mode.
97
98	   The number of programmable endpoints is different through
99	   SOC revisions.
100
101	   Say "y" to link the driver statically, or "m" to build a
102	   dynamically linked module called "fsl_usb2_udc" and force
103	   all gadget drivers to also be dynamically linked.
104
105config USB_FUSB300
106	tristate "Faraday FUSB300 USB Peripheral Controller"
107	depends on !PHYS_ADDR_T_64BIT && HAS_DMA
108	help
109	   Faraday usb device controller FUSB300 driver
110
111config USB_GR_UDC
112	tristate "Aeroflex Gaisler GRUSBDC USB Peripheral Controller Driver"
113	depends on HAS_DMA
114	help
115	  Select this to support Aeroflex Gaisler GRUSBDC cores from the GRLIB
116	  VHDL IP core library.
117
118config USB_OMAP
119	tristate "OMAP USB Device Controller"
120	depends on ARCH_OMAP1
121	help
122	   Many Texas Instruments OMAP processors have flexible full
123	   speed USB device controllers, with support for up to 30
124	   endpoints (plus endpoint zero).  This driver supports the
125	   controller in the OMAP 1611, and should work with controllers
126	   in other OMAP processors too, given minor tweaks.
127
128	   Say "y" to link the driver statically, or "m" to build a
129	   dynamically linked module called "omap_udc" and force all
130	   gadget drivers to also be dynamically linked.
131
132config USB_PXA25X
133	tristate "PXA 25x or IXP 4xx"
134	depends on (ARCH_PXA && PXA25x) || ARCH_IXP4XX
135	depends on HAS_IOMEM
136	help
137	   Intel's PXA 25x series XScale ARM-5TE processors include
138	   an integrated full speed USB 1.1 device controller.  The
139	   controller in the IXP 4xx series is register-compatible.
140
141	   It has fifteen fixed-function endpoints, as well as endpoint
142	   zero (for control transfers).
143
144	   Say "y" to link the driver statically, or "m" to build a
145	   dynamically linked module called "pxa25x_udc" and force all
146	   gadget drivers to also be dynamically linked.
147
148# if there's only one gadget driver, using only two bulk endpoints,
149# don't waste memory for the other endpoints
150config USB_PXA25X_SMALL
151	depends on USB_PXA25X
152	bool
153	default n if USB_ETH_RNDIS
154	default y if USB_ZERO
155	default y if USB_ETH
156	default y if USB_G_SERIAL
157
158config USB_R8A66597
159	tristate "Renesas R8A66597 USB Peripheral Controller"
160	depends on HAS_DMA
161	help
162	   R8A66597 is a discrete USB host and peripheral controller chip that
163	   supports both full and high speed USB 2.0 data transfers.
164	   It has nine configurable endpoints, and endpoint zero.
165
166	   Say "y" to link the driver statically, or "m" to build a
167	   dynamically linked module called "r8a66597_udc" and force all
168	   gadget drivers to also be dynamically linked.
169
170config USB_RENESAS_USBHS_UDC
171	tristate 'Renesas USBHS controller'
172	depends on USB_RENESAS_USBHS
173	help
174	   Renesas USBHS is a discrete USB host and peripheral controller chip
175	   that supports both full and high speed USB 2.0 data transfers.
176	   It has nine or more configurable endpoints, and endpoint zero.
177
178	   Say "y" to link the driver statically, or "m" to build a
179	   dynamically linked module called "renesas_usbhs" and force all
180	   gadget drivers to also be dynamically linked.
181
182config USB_RENESAS_USB3
183	tristate 'Renesas USB3.0 Peripheral controller'
184	depends on ARCH_RENESAS || COMPILE_TEST
185	depends on EXTCON
186	select USB_ROLE_SWITCH
187	help
188	   Renesas USB3.0 Peripheral controller is a USB peripheral controller
189	   that supports super, high, and full speed USB 3.0 data transfers.
190
191	   Say "y" to link the driver statically, or "m" to build a
192	   dynamically linked module called "renesas_usb3" and force all
193	   gadget drivers to also be dynamically linked.
194
195config USB_PXA27X
196	tristate "PXA 27x"
197	depends on HAS_IOMEM
198	help
199	   Intel's PXA 27x series XScale ARM v5TE processors include
200	   an integrated full speed USB 1.1 device controller.
201
202	   It has up to 23 endpoints, as well as endpoint zero (for
203	   control transfers).
204
205	   Say "y" to link the driver statically, or "m" to build a
206	   dynamically linked module called "pxa27x_udc" and force all
207	   gadget drivers to also be dynamically linked.
208
209config USB_MV_UDC
210	tristate "Marvell USB2.0 Device Controller"
211	depends on HAS_DMA
212	help
213	  Marvell Socs (including PXA and MMP series) include a high speed
214	  USB2.0 OTG controller, which can be configured as high speed or
215	  full speed USB peripheral.
216
217config USB_MV_U3D
218	depends on HAS_DMA
219	tristate "MARVELL PXA2128 USB 3.0 controller"
220	help
221	  MARVELL PXA2128 Processor series include a super speed USB3.0 device
222	  controller, which support super speed USB peripheral.
223
224config USB_SNP_CORE
225	depends on (USB_AMD5536UDC || USB_SNP_UDC_PLAT)
226	depends on HAS_DMA
227	tristate
228	help
229	  This enables core driver support for Synopsys USB 2.0 Device
230	  controller.
231
232	  This will be enabled when PCI or Platform driver for this UDC is
233	  selected. Currently, this will be enabled by USB_SNP_UDC_PLAT or
234	  USB_AMD5536UDC options.
235
236	  This IP is different to the High Speed OTG IP that can be enabled
237	  by selecting USB_DWC2 or USB_DWC3 options.
238
239config USB_SNP_UDC_PLAT
240	tristate "Synopsys USB 2.0 Device controller"
241	depends on USB_GADGET && OF && HAS_DMA
242	depends on EXTCON || EXTCON=n
243	select USB_SNP_CORE
244	default ARCH_BCM_IPROC
245	help
246	  This adds Platform Device support for Synopsys Designware core
247	  AHB subsystem USB2.0 Device Controller (UDC).
248
249	  This driver works with UDCs integrated into Broadcom's Northstar2
250	  and Cygnus SoCs.
251
252	  If unsure, say N.
253#
254# Controllers available in both integrated and discrete versions
255#
256
257config USB_M66592
258	tristate "Renesas M66592 USB Peripheral Controller"
259	depends on HAS_IOMEM
260	help
261	   M66592 is a discrete USB peripheral controller chip that
262	   supports both full and high speed USB 2.0 data transfers.
263	   It has seven configurable endpoints, and endpoint zero.
264
265	   Say "y" to link the driver statically, or "m" to build a
266	   dynamically linked module called "m66592_udc" and force all
267	   gadget drivers to also be dynamically linked.
268
269source "drivers/usb/gadget/udc/bdc/Kconfig"
270
271#
272# Controllers available only in discrete form (and all PCI controllers)
273#
274
275config USB_AMD5536UDC
276	tristate "AMD5536 UDC"
277	depends on USB_PCI && HAS_DMA
278	select USB_SNP_CORE
279	help
280	   The AMD5536 UDC is part of the AMD Geode CS5536, an x86 southbridge.
281	   It is a USB Highspeed DMA capable USB device controller. Beside ep0
282	   it provides 4 IN and 4 OUT endpoints (bulk or interrupt type).
283	   The UDC port supports OTG operation, and may be used as a host port
284	   if it's not being used to implement peripheral or OTG roles.
285
286	   This UDC is based on Synopsys USB device controller IP and selects
287	   CONFIG_USB_SNP_CORE option to build the core driver.
288
289	   Say "y" to link the driver statically, or "m" to build a
290	   dynamically linked module called "amd5536udc" and force all
291	   gadget drivers to also be dynamically linked.
292
293config USB_FSL_QE
294	tristate "Freescale QE/CPM USB Device Controller"
295	depends on FSL_SOC && (QUICC_ENGINE || CPM)
296	depends on !64BIT || BROKEN
297	help
298	   Some of Freescale PowerPC processors have a Full Speed
299	   QE/CPM2 USB controller, which support device mode with 4
300	   programmable endpoints. This driver supports the
301	   controller in the MPC8360 and MPC8272, and should work with
302	   controllers having QE or CPM2, given minor tweaks.
303
304	   Set CONFIG_USB_GADGET to "m" to build this driver as a
305	   dynamically linked module called "fsl_qe_udc".
306
307config USB_NET2272
308	depends on HAS_IOMEM
309	tristate "PLX NET2272"
310	help
311	  PLX NET2272 is a USB peripheral controller which supports
312	  both full and high speed USB 2.0 data transfers.
313
314	  It has three configurable endpoints, as well as endpoint zero
315	  (for control transfer).
316	  Say "y" to link the driver statically, or "m" to build a
317	  dynamically linked module called "net2272" and force all
318	  gadget drivers to also be dynamically linked.
319
320config USB_NET2272_DMA
321	bool "Support external DMA controller"
322	depends on USB_NET2272 && HAS_DMA
323	help
324	  The NET2272 part can optionally support an external DMA
325	  controller, but your board has to have support in the
326	  driver itself.
327
328	  If unsure, say "N" here.  The driver works fine in PIO mode.
329
330config USB_NET2280
331	tristate "NetChip NET228x / PLX USB3x8x"
332	depends on USB_PCI
333	help
334	   NetChip 2280 / 2282 is a PCI based USB peripheral controller which
335	   supports both full and high speed USB 2.0 data transfers.
336
337	   It has six configurable endpoints, as well as endpoint zero
338	   (for control transfers) and several endpoints with dedicated
339	   functions.
340
341	   PLX 2380 is a PCIe version of the PLX 2380.
342
343	   PLX 3380 / 3382 is a PCIe based USB peripheral controller which
344	   supports full, high speed USB 2.0 and super speed USB 3.0
345	   data transfers.
346
347	   It has eight configurable endpoints, as well as endpoint zero
348	   (for control transfers) and several endpoints with dedicated
349	   functions.
350
351	   Say "y" to link the driver statically, or "m" to build a
352	   dynamically linked module called "net2280" and force all
353	   gadget drivers to also be dynamically linked.
354
355config USB_GOKU
356	tristate "Toshiba TC86C001 'Goku-S'"
357	depends on USB_PCI
358	help
359	   The Toshiba TC86C001 is a PCI device which includes controllers
360	   for full speed USB devices, IDE, I2C, SIO, plus a USB host (OHCI).
361
362	   The device controller has three configurable (bulk or interrupt)
363	   endpoints, plus endpoint zero (for control transfers).
364
365	   Say "y" to link the driver statically, or "m" to build a
366	   dynamically linked module called "goku_udc" and to force all
367	   gadget drivers to also be dynamically linked.
368
369config USB_EG20T
370	tristate "Intel QUARK X1000/EG20T PCH/LAPIS Semiconductor IOH(ML7213/ML7831) UDC"
371	depends on USB_PCI
372	help
373	  This is a USB device driver for EG20T PCH.
374	  EG20T PCH is the platform controller hub that is used in Intel's
375	  general embedded platform. EG20T PCH has USB device interface.
376	  Using this interface, it is able to access system devices connected
377	  to USB device.
378	  This driver enables USB device function.
379	  USB device is a USB peripheral controller which
380	  supports both full and high speed USB 2.0 data transfers.
381	  This driver supports both control transfer and bulk transfer modes.
382	  This driver dose not support interrupt transfer or isochronous
383	  transfer modes.
384
385	  This driver also can be used for LAPIS Semiconductor's ML7213 which is
386	  for IVI(In-Vehicle Infotainment) use.
387	  ML7831 is for general purpose use.
388	  ML7213/ML7831 is companion chip for Intel Atom E6xx series.
389	  ML7213/ML7831 is completely compatible for Intel EG20T PCH.
390
391	  This driver can be used with Intel's Quark X1000 SOC platform
392
393config USB_GADGET_XILINX
394	tristate "Xilinx USB Driver"
395	depends on HAS_DMA
396	depends on OF
397	help
398	  USB peripheral controller driver for Xilinx USB2 device.
399	  Xilinx USB2 device is a soft IP which supports both full
400	  and high speed USB 2.0 data transfers. It has seven configurable
401	  endpoints(bulk or interrupt or isochronous), as well as
402	  endpoint zero(for control transfers).
403
404	  Say "y" to link the driver statically, or "m" to build a
405	  dynamically linked module called "udc-xilinx" and force all
406	  gadget drivers to also be dynamically linked.
407
408config USB_MAX3420_UDC
409	tristate "MAX3420 (USB-over-SPI) support"
410	depends on SPI
411	help
412	  The Maxim MAX3420 chip supports USB2.0 full-speed peripheral mode.
413	  The MAX3420 is run by SPI interface, and hence the dependency.
414
415	  To compile this driver as a module, choose M here: the module will
416	  be called max3420_udc
417
418config USB_TEGRA_XUDC
419	tristate "NVIDIA Tegra Superspeed USB 3.0 Device Controller"
420	depends on ARCH_TEGRA || COMPILE_TEST
421	depends on PHY_TEGRA_XUSB
422	help
423	 Enables NVIDIA Tegra USB 3.0 device mode controller driver.
424
425	 Say "y" to link the driver statically, or "m" to build a
426	 dynamically linked module called "tegra_xudc" and force all
427	 gadget drivers to also be dynamically linked.
428
429config USB_ASPEED_UDC
430	tristate "Aspeed UDC driver support"
431	depends on ARCH_ASPEED || COMPILE_TEST
432	depends on USB_LIBCOMPOSITE
433	help
434	  Enables Aspeed USB2.0 Device Controller driver for AST260x
435	  family SoCs. The controller supports 1 control endpoint and
436	  4 programmable endpoints.
437
438	  Say "y" to link the driver statically, or "m" to build a
439	  dynamically linked module called "aspeed_udc" and force all
440	  gadget drivers to also be dynamically linked.
441
442source "drivers/usb/gadget/udc/aspeed-vhub/Kconfig"
443
444#
445# LAST -- dummy/emulated controller
446#
447
448config USB_DUMMY_HCD
449	tristate "Dummy HCD (DEVELOPMENT)"
450	depends on USB=y || (USB=m && USB_GADGET=m)
451	help
452	  This host controller driver emulates USB, looping all data transfer
453	  requests back to a USB "gadget driver" in the same host.  The host
454	  side is the controller; the gadget side is the device.  Gadget drivers
455	  can be high, full, or low speed; and they have access to endpoints
456	  like those from NET2280, PXA2xx, or SA1100 hardware.
457
458	  This may help in some stages of creating a driver to embed in a
459	  Linux device, since it lets you debug several parts of the gadget
460	  driver without its hardware or drivers being involved.
461
462	  Since such a gadget side driver needs to interoperate with a host
463	  side Linux-USB device driver, this may help to debug both sides
464	  of a USB protocol stack.
465
466	  Say "y" to link the driver statically, or "m" to build a
467	  dynamically linked module called "dummy_hcd" and force all
468	  gadget drivers to also be dynamically linked.
469
470# NOTE:  Please keep dummy_hcd LAST so that "real hardware" appears
471# first and will be selected by default.
472
473endmenu
474