xref: /linux/drivers/usb/gadget/udc/Kconfig (revision ec5499d338ece9db9b7590649d3cfcc4d7f9603d)
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	depends on ISP1301_OMAP || !(MACH_OMAP_H2 || MACH_OMAP_H3)
122	help
123	   Many Texas Instruments OMAP processors have flexible full
124	   speed USB device controllers, with support for up to 30
125	   endpoints (plus endpoint zero).  This driver supports the
126	   controller in the OMAP 1611, and should work with controllers
127	   in other OMAP processors too, given minor tweaks.
128
129	   Say "y" to link the driver statically, or "m" to build a
130	   dynamically linked module called "omap_udc" and force all
131	   gadget drivers to also be dynamically linked.
132
133config USB_PXA25X
134	tristate "PXA 25x or IXP 4xx"
135	depends on (ARCH_PXA && PXA25x) || ARCH_IXP4XX
136	depends on HAS_IOMEM
137	help
138	   Intel's PXA 25x series XScale ARM-5TE processors include
139	   an integrated full speed USB 1.1 device controller.  The
140	   controller in the IXP 4xx series is register-compatible.
141
142	   It has fifteen fixed-function endpoints, as well as endpoint
143	   zero (for control transfers).
144
145	   Say "y" to link the driver statically, or "m" to build a
146	   dynamically linked module called "pxa25x_udc" and force all
147	   gadget drivers to also be dynamically linked.
148
149# if there's only one gadget driver, using only two bulk endpoints,
150# don't waste memory for the other endpoints
151config USB_PXA25X_SMALL
152	depends on USB_PXA25X
153	bool
154	default n if USB_ETH_RNDIS
155	default y if USB_ZERO
156	default y if USB_ETH
157	default y if USB_G_SERIAL
158
159config USB_R8A66597
160	tristate "Renesas R8A66597 USB Peripheral Controller"
161	depends on HAS_DMA
162	help
163	   R8A66597 is a discrete USB host and peripheral controller chip that
164	   supports both full and high speed USB 2.0 data transfers.
165	   It has nine configurable endpoints, and endpoint zero.
166
167	   Say "y" to link the driver statically, or "m" to build a
168	   dynamically linked module called "r8a66597_udc" and force all
169	   gadget drivers to also be dynamically linked.
170
171config USB_RENESAS_USBHS_UDC
172	tristate 'Renesas USBHS controller'
173	depends on USB_RENESAS_USBHS
174	help
175	   Renesas USBHS is a discrete USB host and peripheral controller chip
176	   that supports both full and high speed USB 2.0 data transfers.
177	   It has nine or more configurable endpoints, and endpoint zero.
178
179	   Say "y" to link the driver statically, or "m" to build a
180	   dynamically linked module called "renesas_usbhs" and force all
181	   gadget drivers to also be dynamically linked.
182
183config USB_RZV2M_USB3DRD
184	tristate 'Renesas USB3.1 DRD controller'
185	depends on ARCH_R9A09G011 || COMPILE_TEST
186	help
187	   Renesas USB3.1 DRD controller is a USB DRD controller
188	   that supports both host and device switching.
189
190	   Say "y" to link the driver statically, or "m" to build a
191	   dynamically linked module called "rzv2m_usb3drd".
192
193config USB_RENESAS_USB3
194	tristate 'Renesas USB3.0 Peripheral controller'
195	depends on ARCH_RENESAS || COMPILE_TEST
196	depends on USB_RZV2M_USB3DRD || !USB_RZV2M_USB3DRD
197	depends on EXTCON
198	select USB_ROLE_SWITCH
199	help
200	   Renesas USB3.0 Peripheral controller is a USB peripheral controller
201	   that supports super, high, and full speed USB 3.0 data transfers.
202
203	   Say "y" to link the driver statically, or "m" to build a
204	   dynamically linked module called "renesas_usb3" and force all
205	   gadget drivers to also be dynamically linked.
206
207config USB_RENESAS_USBF
208	tristate 'Renesas USB Function controller'
209	depends on ARCH_RENESAS || COMPILE_TEST
210	help
211	   Renesas USB Function controller is a USB peripheral controller
212	   available on RZ/N1 Renesas SoCs.
213
214	   Say "y" to link the driver statically, or "m" to build a
215	   dynamically linked module called "renesas_usbf" and force all
216	   gadget drivers to also be dynamically linked.
217
218config USB_PXA27X
219	tristate "PXA 27x"
220	depends on HAS_IOMEM
221	help
222	   Intel's PXA 27x series XScale ARM v5TE processors include
223	   an integrated full speed USB 1.1 device controller.
224
225	   It has up to 23 endpoints, as well as endpoint zero (for
226	   control transfers).
227
228	   Say "y" to link the driver statically, or "m" to build a
229	   dynamically linked module called "pxa27x_udc" and force all
230	   gadget drivers to also be dynamically linked.
231
232config USB_S3C2410
233	tristate "S3C2410 USB Device Controller"
234	depends on ARCH_S3C24XX
235	help
236	  Samsung's S3C2410 is an ARM-4 processor with an integrated
237	  full speed USB 1.1 device controller.  It has 4 configurable
238	  endpoints, as well as endpoint zero (for control transfers).
239
240	  This driver has been tested on the S3C2410, S3C2412, and
241	  S3C2440 processors.
242
243config USB_S3C2410_DEBUG
244	bool "S3C2410 udc debug messages"
245	depends on USB_S3C2410
246
247config USB_S3C_HSUDC
248	tristate "S3C2416, S3C2443 and S3C2450 USB Device Controller"
249	depends on ARCH_S3C24XX
250	help
251	  Samsung's S3C2416, S3C2443 and S3C2450 is an ARM9 based SoC
252	  integrated with dual speed USB 2.0 device controller. It has
253	  8 endpoints, as well as endpoint zero.
254
255	  This driver has been tested on S3C2416 and S3C2450 processors.
256
257config USB_MV_UDC
258	tristate "Marvell USB2.0 Device Controller"
259	depends on HAS_DMA
260	help
261	  Marvell Socs (including PXA and MMP series) include a high speed
262	  USB2.0 OTG controller, which can be configured as high speed or
263	  full speed USB peripheral.
264
265config USB_MV_U3D
266	depends on HAS_DMA
267	tristate "MARVELL PXA2128 USB 3.0 controller"
268	help
269	  MARVELL PXA2128 Processor series include a super speed USB3.0 device
270	  controller, which support super speed USB peripheral.
271
272config USB_SNP_CORE
273	depends on (USB_AMD5536UDC || USB_SNP_UDC_PLAT)
274	depends on HAS_DMA
275	tristate
276	help
277	  This enables core driver support for Synopsys USB 2.0 Device
278	  controller.
279
280	  This will be enabled when PCI or Platform driver for this UDC is
281	  selected. Currently, this will be enabled by USB_SNP_UDC_PLAT or
282	  USB_AMD5536UDC options.
283
284	  This IP is different to the High Speed OTG IP that can be enabled
285	  by selecting USB_DWC2 or USB_DWC3 options.
286
287config USB_SNP_UDC_PLAT
288	tristate "Synopsys USB 2.0 Device controller"
289	depends on USB_GADGET && OF && HAS_DMA
290	depends on EXTCON || EXTCON=n
291	select USB_SNP_CORE
292	default ARCH_BCM_IPROC
293	help
294	  This adds Platform Device support for Synopsys Designware core
295	  AHB subsystem USB2.0 Device Controller (UDC).
296
297	  This driver works with UDCs integrated into Broadcom's Northstar2
298	  and Cygnus SoCs.
299
300	  If unsure, say N.
301#
302# Controllers available in both integrated and discrete versions
303#
304
305config USB_M66592
306	tristate "Renesas M66592 USB Peripheral Controller"
307	depends on HAS_IOMEM
308	help
309	   M66592 is a discrete USB peripheral controller chip that
310	   supports both full and high speed USB 2.0 data transfers.
311	   It has seven configurable endpoints, and endpoint zero.
312
313	   Say "y" to link the driver statically, or "m" to build a
314	   dynamically linked module called "m66592_udc" and force all
315	   gadget drivers to also be dynamically linked.
316
317source "drivers/usb/gadget/udc/bdc/Kconfig"
318
319#
320# Controllers available only in discrete form (and all PCI controllers)
321#
322
323config USB_AMD5536UDC
324	tristate "AMD5536 UDC"
325	depends on USB_PCI && HAS_DMA
326	select USB_SNP_CORE
327	help
328	   The AMD5536 UDC is part of the AMD Geode CS5536, an x86 southbridge.
329	   It is a USB Highspeed DMA capable USB device controller. Beside ep0
330	   it provides 4 IN and 4 OUT endpoints (bulk or interrupt type).
331	   The UDC port supports OTG operation, and may be used as a host port
332	   if it's not being used to implement peripheral or OTG roles.
333
334	   This UDC is based on Synopsys USB device controller IP and selects
335	   CONFIG_USB_SNP_CORE option to build the core driver.
336
337	   Say "y" to link the driver statically, or "m" to build a
338	   dynamically linked module called "amd5536udc" and force all
339	   gadget drivers to also be dynamically linked.
340
341config USB_FSL_QE
342	tristate "Freescale QE/CPM USB Device Controller"
343	depends on FSL_SOC && (QUICC_ENGINE || CPM)
344	depends on !64BIT || BROKEN
345	help
346	   Some of Freescale PowerPC processors have a Full Speed
347	   QE/CPM2 USB controller, which support device mode with 4
348	   programmable endpoints. This driver supports the
349	   controller in the MPC8360 and MPC8272, and should work with
350	   controllers having QE or CPM2, given minor tweaks.
351
352	   Set CONFIG_USB_GADGET to "m" to build this driver as a
353	   dynamically linked module called "fsl_qe_udc".
354
355config USB_NET2272
356	depends on HAS_IOMEM
357	tristate "PLX NET2272"
358	help
359	  PLX NET2272 is a USB peripheral controller which supports
360	  both full and high speed USB 2.0 data transfers.
361
362	  It has three configurable endpoints, as well as endpoint zero
363	  (for control transfer).
364	  Say "y" to link the driver statically, or "m" to build a
365	  dynamically linked module called "net2272" and force all
366	  gadget drivers to also be dynamically linked.
367
368config USB_NET2272_DMA
369	bool "Support external DMA controller"
370	depends on USB_NET2272 && HAS_DMA
371	help
372	  The NET2272 part can optionally support an external DMA
373	  controller, but your board has to have support in the
374	  driver itself.
375
376	  If unsure, say "N" here.  The driver works fine in PIO mode.
377
378config USB_NET2280
379	tristate "NetChip NET228x / PLX USB3x8x"
380	depends on USB_PCI
381	help
382	   NetChip 2280 / 2282 is a PCI based USB peripheral controller which
383	   supports both full and high speed USB 2.0 data transfers.
384
385	   It has six configurable endpoints, as well as endpoint zero
386	   (for control transfers) and several endpoints with dedicated
387	   functions.
388
389	   PLX 2380 is a PCIe version of the PLX 2380.
390
391	   PLX 3380 / 3382 is a PCIe based USB peripheral controller which
392	   supports full, high speed USB 2.0 and super speed USB 3.0
393	   data transfers.
394
395	   It has eight configurable endpoints, as well as endpoint zero
396	   (for control transfers) and several endpoints with dedicated
397	   functions.
398
399	   Say "y" to link the driver statically, or "m" to build a
400	   dynamically linked module called "net2280" and force all
401	   gadget drivers to also be dynamically linked.
402
403config USB_GOKU
404	tristate "Toshiba TC86C001 'Goku-S'"
405	depends on USB_PCI
406	help
407	   The Toshiba TC86C001 is a PCI device which includes controllers
408	   for full speed USB devices, IDE, I2C, SIO, plus a USB host (OHCI).
409
410	   The device controller has three configurable (bulk or interrupt)
411	   endpoints, plus endpoint zero (for control transfers).
412
413	   Say "y" to link the driver statically, or "m" to build a
414	   dynamically linked module called "goku_udc" and to force all
415	   gadget drivers to also be dynamically linked.
416
417config USB_EG20T
418	tristate "Intel QUARK X1000/EG20T PCH/LAPIS Semiconductor IOH(ML7213/ML7831) UDC"
419	depends on USB_PCI
420	help
421	  This is a USB device driver for EG20T PCH.
422	  EG20T PCH is the platform controller hub that is used in Intel's
423	  general embedded platform. EG20T PCH has USB device interface.
424	  Using this interface, it is able to access system devices connected
425	  to USB device.
426	  This driver enables USB device function.
427	  USB device is a USB peripheral controller which
428	  supports both full and high speed USB 2.0 data transfers.
429	  This driver supports both control transfer and bulk transfer modes.
430	  This driver dose not support interrupt transfer or isochronous
431	  transfer modes.
432
433	  This driver also can be used for LAPIS Semiconductor's ML7213 which is
434	  for IVI(In-Vehicle Infotainment) use.
435	  ML7831 is for general purpose use.
436	  ML7213/ML7831 is companion chip for Intel Atom E6xx series.
437	  ML7213/ML7831 is completely compatible for Intel EG20T PCH.
438
439	  This driver can be used with Intel's Quark X1000 SOC platform
440
441config USB_GADGET_XILINX
442	tristate "Xilinx USB Driver"
443	depends on HAS_DMA
444	depends on OF
445	help
446	  USB peripheral controller driver for Xilinx USB2 device.
447	  Xilinx USB2 device is a soft IP which supports both full
448	  and high speed USB 2.0 data transfers. It has seven configurable
449	  endpoints(bulk or interrupt or isochronous), as well as
450	  endpoint zero(for control transfers).
451
452	  Say "y" to link the driver statically, or "m" to build a
453	  dynamically linked module called "udc-xilinx" and force all
454	  gadget drivers to also be dynamically linked.
455
456config USB_MAX3420_UDC
457	tristate "MAX3420 (USB-over-SPI) support"
458	depends on SPI
459	help
460	  The Maxim MAX3420 chip supports USB2.0 full-speed peripheral mode.
461	  The MAX3420 is run by SPI interface, and hence the dependency.
462
463	  To compile this driver as a module, choose M here: the module will
464	  be called max3420_udc
465
466config USB_TEGRA_XUDC
467	tristate "NVIDIA Tegra Superspeed USB 3.0 Device Controller"
468	depends on ARCH_TEGRA || COMPILE_TEST
469	depends on PHY_TEGRA_XUSB
470	help
471	 Enables NVIDIA Tegra USB 3.0 device mode controller driver.
472
473	 Say "y" to link the driver statically, or "m" to build a
474	 dynamically linked module called "tegra_xudc" and force all
475	 gadget drivers to also be dynamically linked.
476
477config USB_ASPEED_UDC
478	tristate "Aspeed UDC driver support"
479	depends on ARCH_ASPEED || COMPILE_TEST
480	depends on USB_LIBCOMPOSITE
481	help
482	  Enables Aspeed USB2.0 Device Controller driver for AST260x
483	  family SoCs. The controller supports 1 control endpoint and
484	  4 programmable endpoints.
485
486	  Say "y" to link the driver statically, or "m" to build a
487	  dynamically linked module called "aspeed_udc" and force all
488	  gadget drivers to also be dynamically linked.
489
490source "drivers/usb/gadget/udc/aspeed-vhub/Kconfig"
491
492#
493# LAST -- dummy/emulated controller
494#
495
496config USB_DUMMY_HCD
497	tristate "Dummy HCD (DEVELOPMENT)"
498	depends on USB=y || (USB=m && USB_GADGET=m)
499	help
500	  This host controller driver emulates USB, looping all data transfer
501	  requests back to a USB "gadget driver" in the same host.  The host
502	  side is the controller; the gadget side is the device.  Gadget drivers
503	  can be high, full, or low speed; and they have access to endpoints
504	  like those from NET2280, PXA2xx, or SA1100 hardware.
505
506	  This may help in some stages of creating a driver to embed in a
507	  Linux device, since it lets you debug several parts of the gadget
508	  driver without its hardware or drivers being involved.
509
510	  Since such a gadget side driver needs to interoperate with a host
511	  side Linux-USB device driver, this may help to debug both sides
512	  of a USB protocol stack.
513
514	  Say "y" to link the driver statically, or "m" to build a
515	  dynamically linked module called "dummy_hcd" and force all
516	  gadget drivers to also be dynamically linked.
517
518# NOTE:  Please keep dummy_hcd LAST so that "real hardware" appears
519# first and will be selected by default.
520
521endmenu
522