xref: /openbmc/linux/drivers/usb/gadget/Kconfig (revision 90fccb52)
11da177e4SLinus Torvalds#
21da177e4SLinus Torvalds# USB Gadget support on a system involves
31da177e4SLinus Torvalds#    (a) a peripheral controller, and
41da177e4SLinus Torvalds#    (b) the gadget driver using it.
51da177e4SLinus Torvalds#
61da177e4SLinus Torvalds# NOTE:  Gadget support ** DOES NOT ** depend on host-side CONFIG_USB !!
71da177e4SLinus Torvalds#
81da177e4SLinus Torvalds#  - Host systems (like PCs) need CONFIG_USB (with "A" jacks).
91da177e4SLinus Torvalds#  - Peripherals (like PDAs) need CONFIG_USB_GADGET (with "B" jacks).
10cab00891SMatt LaPlante#  - Some systems have both kinds of controllers.
111da177e4SLinus Torvalds#
121da177e4SLinus Torvalds# With help from a special transceiver and a "Mini-AB" jack, systems with
131da177e4SLinus Torvalds# both kinds of controller can also support "USB On-the-Go" (CONFIG_USB_OTG).
141da177e4SLinus Torvalds#
151da177e4SLinus Torvalds
16b75be4abSDenis Chengmenuconfig USB_GADGET
17b75be4abSDenis Cheng	tristate "USB Gadget Support"
1886dc243cSAlan Stern	select NLS
191da177e4SLinus Torvalds	help
201da177e4SLinus Torvalds	   USB is a master/slave protocol, organized with one master
211da177e4SLinus Torvalds	   host (such as a PC) controlling up to 127 peripheral devices.
221da177e4SLinus Torvalds	   The USB hardware is asymmetric, which makes it easier to set up:
231da177e4SLinus Torvalds	   you can't connect a "to-the-host" connector to a peripheral.
241da177e4SLinus Torvalds
251da177e4SLinus Torvalds	   Linux can run in the host, or in the peripheral.  In both cases
261da177e4SLinus Torvalds	   you need a low level bus controller driver, and some software
271da177e4SLinus Torvalds	   talking to it.  Peripheral controllers are often discrete silicon,
281da177e4SLinus Torvalds	   or are integrated with the CPU in a microcontroller.  The more
29e113f29cSJules Villard	   familiar host side controllers have names like "EHCI", "OHCI",
301da177e4SLinus Torvalds	   or "UHCI", and are usually integrated into southbridges on PC
311da177e4SLinus Torvalds	   motherboards.
321da177e4SLinus Torvalds
331da177e4SLinus Torvalds	   Enable this configuration option if you want to run Linux inside
341da177e4SLinus Torvalds	   a USB peripheral device.  Configure one hardware driver for your
351da177e4SLinus Torvalds	   peripheral/device side bus controller, and a "gadget driver" for
361da177e4SLinus Torvalds	   your peripheral protocol.  (If you use modular gadget drivers,
371da177e4SLinus Torvalds	   you may configure more than one.)
381da177e4SLinus Torvalds
391da177e4SLinus Torvalds	   If in doubt, say "N" and don't enable these drivers; most people
401da177e4SLinus Torvalds	   don't have this kind of hardware (except maybe inside Linux PDAs).
411da177e4SLinus Torvalds
421da177e4SLinus Torvalds	   For more information, see <http://www.linux-usb.org/gadget> and
431da177e4SLinus Torvalds	   the kernel DocBook documentation for this API.
441da177e4SLinus Torvalds
45b75be4abSDenis Chengif USB_GADGET
46b75be4abSDenis Cheng
4770790f63SDavid Brownellconfig USB_GADGET_DEBUG
48afd0e0f2SRobert P. J. Day	boolean "Debugging messages (DEVELOPMENT)"
4936e893d2SDavid Brownell	depends on DEBUG_KERNEL
5070790f63SDavid Brownell	help
5170790f63SDavid Brownell	   Many controller and gadget drivers will print some debugging
5270790f63SDavid Brownell	   messages if you use this option to ask for those messages.
5370790f63SDavid Brownell
5470790f63SDavid Brownell	   Avoid enabling these messages, even if you're actively
5570790f63SDavid Brownell	   debugging such a driver.  Many drivers will emit so many
5670790f63SDavid Brownell	   messages that the driver timings are affected, which will
5770790f63SDavid Brownell	   either create new failure modes or remove the one you're
5870790f63SDavid Brownell	   trying to track down.  Never enable these messages for a
5970790f63SDavid Brownell	   production build.
6070790f63SDavid Brownell
61cd108691SAndreas Larssonconfig USB_GADGET_VERBOSE
62cd108691SAndreas Larsson	bool "Verbose debugging Messages (DEVELOPMENT)"
63cd108691SAndreas Larsson	depends on USB_GADGET_DEBUG
64cd108691SAndreas Larsson	help
65cd108691SAndreas Larsson	   Many controller and gadget drivers will print verbose debugging
66cd108691SAndreas Larsson	   messages if you use this option to ask for those messages.
67cd108691SAndreas Larsson
68cd108691SAndreas Larsson	   Avoid enabling these messages, even if you're actively
69cd108691SAndreas Larsson	   debugging such a driver.  Many drivers will emit so many
70cd108691SAndreas Larsson	   messages that the driver timings are affected, which will
71cd108691SAndreas Larsson	   either create new failure modes or remove the one you're
72cd108691SAndreas Larsson	   trying to track down.  Never enable these messages for a
73cd108691SAndreas Larsson	   production build.
74cd108691SAndreas Larsson
751da177e4SLinus Torvaldsconfig USB_GADGET_DEBUG_FILES
76afd0e0f2SRobert P. J. Day	boolean "Debugging information files (DEVELOPMENT)"
7736e893d2SDavid Brownell	depends on PROC_FS
781da177e4SLinus Torvalds	help
791da177e4SLinus Torvalds	   Some of the drivers in the "gadget" framework can expose
801da177e4SLinus Torvalds	   debugging information in files such as /proc/driver/udc
811da177e4SLinus Torvalds	   (for a peripheral controller).  The information in these
821da177e4SLinus Torvalds	   files may help when you're troubleshooting or bringing up a
831da177e4SLinus Torvalds	   driver on a new board.   Enable these files by choosing "Y"
841da177e4SLinus Torvalds	   here.  If in doubt, or to conserve kernel memory, say "N".
851da177e4SLinus Torvalds
86914a3f3bSHaavard Skinnemoenconfig USB_GADGET_DEBUG_FS
87afd0e0f2SRobert P. J. Day	boolean "Debugging information files in debugfs (DEVELOPMENT)"
8836e893d2SDavid Brownell	depends on DEBUG_FS
89914a3f3bSHaavard Skinnemoen	help
90914a3f3bSHaavard Skinnemoen	   Some of the drivers in the "gadget" framework can expose
91914a3f3bSHaavard Skinnemoen	   debugging information in files under /sys/kernel/debug/.
92914a3f3bSHaavard Skinnemoen	   The information in these files may help when you're
93914a3f3bSHaavard Skinnemoen	   troubleshooting or bringing up a driver on a new board.
94914a3f3bSHaavard Skinnemoen	   Enable these files by choosing "Y" here.  If in doubt, or
95914a3f3bSHaavard Skinnemoen	   to conserve kernel memory, say "N".
96914a3f3bSHaavard Skinnemoen
9736e893d2SDavid Brownellconfig USB_GADGET_VBUS_DRAW
9836e893d2SDavid Brownell	int "Maximum VBUS Power usage (2-500 mA)"
9936e893d2SDavid Brownell	range 2 500
10036e893d2SDavid Brownell	default 2
10136e893d2SDavid Brownell	help
10236e893d2SDavid Brownell	   Some devices need to draw power from USB when they are
10336e893d2SDavid Brownell	   configured, perhaps to operate circuitry or to recharge
10436e893d2SDavid Brownell	   batteries.  This is in addition to any local power supply,
10536e893d2SDavid Brownell	   such as an AC adapter or batteries.
10636e893d2SDavid Brownell
10736e893d2SDavid Brownell	   Enter the maximum power your device draws through USB, in
10836e893d2SDavid Brownell	   milliAmperes.  The permitted range of values is 2 - 500 mA;
10936e893d2SDavid Brownell	   0 mA would be legal, but can make some hosts misbehave.
11036e893d2SDavid Brownell
11136e893d2SDavid Brownell	   This value will be used except for system-specific gadget
11236e893d2SDavid Brownell	   drivers that have more specific information.
11336e893d2SDavid Brownell
1146532c7fdSPer Forlinconfig USB_GADGET_STORAGE_NUM_BUFFERS
1156532c7fdSPer Forlin	int "Number of storage pipeline buffers"
1166532c7fdSPer Forlin	range 2 4
1176532c7fdSPer Forlin	default 2
1186532c7fdSPer Forlin	help
1196532c7fdSPer Forlin	   Usually 2 buffers are enough to establish a good buffering
1206532c7fdSPer Forlin	   pipeline. The number may be increased in order to compensate
1216532c7fdSPer Forlin	   for a bursty VFS behaviour. For instance there may be CPU wake up
1226532c7fdSPer Forlin	   latencies that makes the VFS to appear bursty in a system with
1236532c7fdSPer Forlin	   an CPU on-demand governor. Especially if DMA is doing IO to
1246532c7fdSPer Forlin	   offload the CPU. In this case the CPU will go into power
1256532c7fdSPer Forlin	   save often and spin up occasionally to move data within VFS.
1266532c7fdSPer Forlin	   If selecting USB_GADGET_DEBUG_FILES this value may be set by
1276532c7fdSPer Forlin	   a module parameter as well.
1286532c7fdSPer Forlin	   If unsure, say 2.
1296532c7fdSPer Forlin
13090fccb52SAndrzej Pietrasiewiczsource "drivers/usb/gadget/udc/Kconfig"
1311da177e4SLinus Torvalds
1321da177e4SLinus Torvalds#
1331da177e4SLinus Torvalds# USB Gadget Drivers
1341da177e4SLinus Torvalds#
135a84d9e53SSebastian Andrzej Siewior
136a84d9e53SSebastian Andrzej Siewior# composite based drivers
137a84d9e53SSebastian Andrzej Siewiorconfig USB_LIBCOMPOSITE
138a84d9e53SSebastian Andrzej Siewior	tristate
13988af8bbeSSebastian Andrzej Siewior	select CONFIGFS_FS
140a84d9e53SSebastian Andrzej Siewior	depends on USB_GADGET
141a84d9e53SSebastian Andrzej Siewior
142ff47f594SSebastian Andrzej Siewiorconfig USB_F_ACM
143ff47f594SSebastian Andrzej Siewior	tristate
144ff47f594SSebastian Andrzej Siewior
145cf9a08aeSSebastian Andrzej Siewiorconfig USB_F_SS_LB
146cf9a08aeSSebastian Andrzej Siewior	tristate
147cf9a08aeSSebastian Andrzej Siewior
1483249ca22SSebastian Andrzej Siewiorconfig USB_U_SERIAL
1493249ca22SSebastian Andrzej Siewior	tristate
1503249ca22SSebastian Andrzej Siewior
151f1a1823fSAndrzej Pietrasiewiczconfig USB_U_ETHER
152f1a1823fSAndrzej Pietrasiewicz	tristate
153f1a1823fSAndrzej Pietrasiewicz
15460540ea2SAndrzej Pietrasiewiczconfig USB_F_SERIAL
15560540ea2SAndrzej Pietrasiewicz	tristate
15660540ea2SAndrzej Pietrasiewicz
1571d8fc251SAndrzej Pietrasiewiczconfig USB_F_OBEX
1581d8fc251SAndrzej Pietrasiewicz	tristate
1591d8fc251SAndrzej Pietrasiewicz
16040d133d7SAndrzej Pietrasiewiczconfig USB_F_NCM
16140d133d7SAndrzej Pietrasiewicz	tristate
16240d133d7SAndrzej Pietrasiewicz
163fee562a6SAndrzej Pietrasiewiczconfig USB_F_ECM
164fee562a6SAndrzej Pietrasiewicz	tristate
165fee562a6SAndrzej Pietrasiewicz
166fcbdf12eSAndrzej Pietrasiewiczconfig USB_F_PHONET
167fcbdf12eSAndrzej Pietrasiewicz	tristate
168fcbdf12eSAndrzej Pietrasiewicz
169b29002a1SAndrzej Pietrasiewiczconfig USB_F_EEM
170b29002a1SAndrzej Pietrasiewicz	tristate
171b29002a1SAndrzej Pietrasiewicz
1728cedba7cSAndrzej Pietrasiewiczconfig USB_F_SUBSET
1738cedba7cSAndrzej Pietrasiewicz	tristate
1748cedba7cSAndrzej Pietrasiewicz
175f466c635SAndrzej Pietrasiewiczconfig USB_F_RNDIS
176f466c635SAndrzej Pietrasiewicz	tristate
177f466c635SAndrzej Pietrasiewicz
178e5eaa0dcSAndrzej Pietrasiewiczconfig USB_F_MASS_STORAGE
179e5eaa0dcSAndrzej Pietrasiewicz	tristate
180e5eaa0dcSAndrzej Pietrasiewicz
1815920cda6SAndrzej Pietrasiewiczconfig USB_F_FS
1825920cda6SAndrzej Pietrasiewicz	tristate
1835920cda6SAndrzej Pietrasiewicz
1841da177e4SLinus Torvaldschoice
1851da177e4SLinus Torvalds	tristate "USB Gadget Drivers"
1861da177e4SLinus Torvalds	default USB_ETH
1871da177e4SLinus Torvalds	help
1881da177e4SLinus Torvalds	  A Linux "Gadget Driver" talks to the USB Peripheral Controller
1891da177e4SLinus Torvalds	  driver through the abstract "gadget" API.  Some other operating
1901da177e4SLinus Torvalds	  systems call these "client" drivers, of which "class drivers"
1911da177e4SLinus Torvalds	  are a subset (implementing a USB device class specification).
1921da177e4SLinus Torvalds	  A gadget driver implements one or more USB functions using
1931da177e4SLinus Torvalds	  the peripheral hardware.
1941da177e4SLinus Torvalds
1951da177e4SLinus Torvalds	  Gadget drivers are hardware-neutral, or "platform independent",
1961da177e4SLinus Torvalds	  except that they sometimes must understand quirks or limitations
1971da177e4SLinus Torvalds	  of the particular controllers they work with.  For example, when
1981da177e4SLinus Torvalds	  a controller doesn't support alternate configurations or provide
1991da177e4SLinus Torvalds	  enough of the right types of endpoints, the gadget driver might
2001da177e4SLinus Torvalds	  not be able work with that controller, or might need to implement
2011da177e4SLinus Torvalds	  a less common variant of a device class protocol.
2021da177e4SLinus Torvalds
2031da177e4SLinus Torvalds# this first set of drivers all depend on bulk-capable hardware.
2041da177e4SLinus Torvalds
205d1c02452SAndrzej Pietrasiewiczconfig USB_CONFIGFS
206d1c02452SAndrzej Pietrasiewicz	tristate "USB functions configurable through configfs"
207d1c02452SAndrzej Pietrasiewicz	select USB_LIBCOMPOSITE
208d1c02452SAndrzej Pietrasiewicz	help
209d1c02452SAndrzej Pietrasiewicz	  A Linux USB "gadget" can be set up through configfs.
210d1c02452SAndrzej Pietrasiewicz	  If this is the case, the USB functions (which from the host's
211d1c02452SAndrzej Pietrasiewicz	  perspective are seen as interfaces) and configurations are
212d1c02452SAndrzej Pietrasiewicz	  specified simply by creating appropriate directories in configfs.
213d1c02452SAndrzej Pietrasiewicz	  Associating functions with configurations is done by creating
214d1c02452SAndrzej Pietrasiewicz	  appropriate symbolic links.
2159c1d6962SPhilippe De Swert	  For more information see Documentation/usb/gadget_configfs.txt.
216d1c02452SAndrzej Pietrasiewicz
217d1c02452SAndrzej Pietrasiewiczconfig USB_CONFIGFS_SERIAL
218d1c02452SAndrzej Pietrasiewicz	boolean "Generic serial bulk in/out"
219d1c02452SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
220d1c02452SAndrzej Pietrasiewicz	depends on TTY
221d1c02452SAndrzej Pietrasiewicz	select USB_U_SERIAL
222d1c02452SAndrzej Pietrasiewicz	select USB_F_SERIAL
223d1c02452SAndrzej Pietrasiewicz	help
224d1c02452SAndrzej Pietrasiewicz	  The function talks to the Linux-USB generic serial driver.
225d1c02452SAndrzej Pietrasiewicz
226d1c02452SAndrzej Pietrasiewiczconfig USB_CONFIGFS_ACM
227d1c02452SAndrzej Pietrasiewicz	boolean "Abstract Control Model (CDC ACM)"
228d1c02452SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
229d1c02452SAndrzej Pietrasiewicz	depends on TTY
230d1c02452SAndrzej Pietrasiewicz	select USB_U_SERIAL
231d1c02452SAndrzej Pietrasiewicz	select USB_F_ACM
232d1c02452SAndrzej Pietrasiewicz	help
233d1c02452SAndrzej Pietrasiewicz	  ACM serial link.  This function can be used to interoperate with
234d1c02452SAndrzej Pietrasiewicz	  MS-Windows hosts or with the Linux-USB "cdc-acm" driver.
235d1c02452SAndrzej Pietrasiewicz
236d1c02452SAndrzej Pietrasiewiczconfig USB_CONFIGFS_OBEX
237d1c02452SAndrzej Pietrasiewicz	boolean "Object Exchange Model (CDC OBEX)"
238d1c02452SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
239d1c02452SAndrzej Pietrasiewicz	depends on TTY
240d1c02452SAndrzej Pietrasiewicz	select USB_U_SERIAL
241d1c02452SAndrzej Pietrasiewicz	select USB_F_OBEX
242d1c02452SAndrzej Pietrasiewicz	help
243d1c02452SAndrzej Pietrasiewicz	  You will need a user space OBEX server talking to /dev/ttyGS*,
244d1c02452SAndrzej Pietrasiewicz	  since the kernel itself doesn't implement the OBEX protocol.
245d1c02452SAndrzej Pietrasiewicz
246d1c02452SAndrzej Pietrasiewiczconfig USB_CONFIGFS_NCM
247d1c02452SAndrzej Pietrasiewicz	boolean "Network Control Model (CDC NCM)"
248d1c02452SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
249d1c02452SAndrzej Pietrasiewicz	depends on NET
250d1c02452SAndrzej Pietrasiewicz	select USB_U_ETHER
251d1c02452SAndrzej Pietrasiewicz	select USB_F_NCM
252d1c02452SAndrzej Pietrasiewicz	help
253d1c02452SAndrzej Pietrasiewicz	  NCM is an advanced protocol for Ethernet encapsulation, allows
254d1c02452SAndrzej Pietrasiewicz	  grouping of several ethernet frames into one USB transfer and
255d1c02452SAndrzej Pietrasiewicz	  different alignment possibilities.
256d1c02452SAndrzej Pietrasiewicz
257d1c02452SAndrzej Pietrasiewiczconfig USB_CONFIGFS_ECM
258d1c02452SAndrzej Pietrasiewicz	boolean "Ethernet Control Model (CDC ECM)"
259d1c02452SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
260d1c02452SAndrzej Pietrasiewicz	depends on NET
261d1c02452SAndrzej Pietrasiewicz	select USB_U_ETHER
262d1c02452SAndrzej Pietrasiewicz	select USB_F_ECM
263d1c02452SAndrzej Pietrasiewicz	help
264d1c02452SAndrzej Pietrasiewicz	  The "Communication Device Class" (CDC) Ethernet Control Model.
265d1c02452SAndrzej Pietrasiewicz	  That protocol is often avoided with pure Ethernet adapters, in
266d1c02452SAndrzej Pietrasiewicz	  favor of simpler vendor-specific hardware, but is widely
267d1c02452SAndrzej Pietrasiewicz	  supported by firmware for smart network devices.
268d1c02452SAndrzej Pietrasiewicz
26902832e56SAndrzej Pietrasiewiczconfig USB_CONFIGFS_ECM_SUBSET
27002832e56SAndrzej Pietrasiewicz	boolean "Ethernet Control Model (CDC ECM) subset"
27102832e56SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
27202832e56SAndrzej Pietrasiewicz	depends on NET
27302832e56SAndrzej Pietrasiewicz	select USB_U_ETHER
27402832e56SAndrzej Pietrasiewicz	select USB_F_SUBSET
27502832e56SAndrzej Pietrasiewicz	help
27602832e56SAndrzej Pietrasiewicz	  On hardware that can't implement the full protocol,
27702832e56SAndrzej Pietrasiewicz	  a simple CDC subset is used, placing fewer demands on USB.
27802832e56SAndrzej Pietrasiewicz
279b3df2faaSAndrzej Pietrasiewiczconfig USB_CONFIGFS_RNDIS
280b3df2faaSAndrzej Pietrasiewicz	bool "RNDIS"
281b3df2faaSAndrzej Pietrasiewicz	depends on USB_CONFIGFS
282b3df2faaSAndrzej Pietrasiewicz	depends on NET
283b3df2faaSAndrzej Pietrasiewicz	select USB_U_ETHER
284b3df2faaSAndrzej Pietrasiewicz	select USB_F_RNDIS
285b3df2faaSAndrzej Pietrasiewicz	help
286b3df2faaSAndrzej Pietrasiewicz	   Microsoft Windows XP bundles the "Remote NDIS" (RNDIS) protocol,
287b3df2faaSAndrzej Pietrasiewicz	   and Microsoft provides redistributable binary RNDIS drivers for
288b3df2faaSAndrzej Pietrasiewicz	   older versions of Windows.
289b3df2faaSAndrzej Pietrasiewicz
290b3df2faaSAndrzej Pietrasiewicz	   To make MS-Windows work with this, use Documentation/usb/linux.inf
291b3df2faaSAndrzej Pietrasiewicz	   as the "driver info file".  For versions of MS-Windows older than
292b3df2faaSAndrzej Pietrasiewicz	   XP, you'll need to download drivers from Microsoft's website; a URL
293b3df2faaSAndrzej Pietrasiewicz	   is given in comments found in that info file.
294b3df2faaSAndrzej Pietrasiewicz
29517b80976SAndrzej Pietrasiewiczconfig USB_CONFIGFS_EEM
29617b80976SAndrzej Pietrasiewicz	bool "Ethernet Emulation Model (EEM)"
29717b80976SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
29817b80976SAndrzej Pietrasiewicz	depends on NET
29917b80976SAndrzej Pietrasiewicz	select USB_U_ETHER
30017b80976SAndrzej Pietrasiewicz	select USB_F_EEM
30117b80976SAndrzej Pietrasiewicz	help
30217b80976SAndrzej Pietrasiewicz	  CDC EEM is a newer USB standard that is somewhat simpler than CDC ECM
30317b80976SAndrzej Pietrasiewicz	  and therefore can be supported by more hardware.  Technically ECM and
30417b80976SAndrzej Pietrasiewicz	  EEM are designed for different applications.  The ECM model extends
30517b80976SAndrzej Pietrasiewicz	  the network interface to the target (e.g. a USB cable modem), and the
30617b80976SAndrzej Pietrasiewicz	  EEM model is for mobile devices to communicate with hosts using
30717b80976SAndrzej Pietrasiewicz	  ethernet over USB.  For Linux gadgets, however, the interface with
30817b80976SAndrzej Pietrasiewicz	  the host is the same (a usbX device), so the differences are minimal.
30917b80976SAndrzej Pietrasiewicz
31083408745SAndrzej Pietrasiewiczconfig USB_CONFIGFS_PHONET
31183408745SAndrzej Pietrasiewicz	boolean "Phonet protocol"
31283408745SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
31383408745SAndrzej Pietrasiewicz	depends on NET
31483408745SAndrzej Pietrasiewicz	depends on PHONET
31583408745SAndrzej Pietrasiewicz	select USB_U_ETHER
31683408745SAndrzej Pietrasiewicz	select USB_F_PHONET
31783408745SAndrzej Pietrasiewicz	help
31883408745SAndrzej Pietrasiewicz	  The Phonet protocol implementation for USB device.
31983408745SAndrzej Pietrasiewicz
320ef0aa4b9SAndrzej Pietrasiewiczconfig USB_CONFIGFS_MASS_STORAGE
321ef0aa4b9SAndrzej Pietrasiewicz	boolean "Mass storage"
322ef0aa4b9SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
323bc912b0dSAndrzej Pietrasiewicz	depends on BLOCK
324ef0aa4b9SAndrzej Pietrasiewicz	select USB_F_MASS_STORAGE
325ef0aa4b9SAndrzej Pietrasiewicz	help
326ef0aa4b9SAndrzej Pietrasiewicz	  The Mass Storage Gadget acts as a USB Mass Storage disk drive.
327ef0aa4b9SAndrzej Pietrasiewicz	  As its storage repository it can use a regular file or a block
328ef0aa4b9SAndrzej Pietrasiewicz	  device (in much the same way as the "loop" device driver),
329ef0aa4b9SAndrzej Pietrasiewicz	  specified as a module parameter or sysfs option.
330ef0aa4b9SAndrzej Pietrasiewicz
33125d80151SAndrzej Pietrasiewiczconfig USB_CONFIGFS_F_LB_SS
33225d80151SAndrzej Pietrasiewicz	boolean "Loopback and sourcesink function (for testing)"
333c0501f47SAndrzej Pietrasiewicz	depends on USB_CONFIGFS
334c0501f47SAndrzej Pietrasiewicz	select USB_F_SS_LB
335c0501f47SAndrzej Pietrasiewicz	help
33625d80151SAndrzej Pietrasiewicz	  Loopback function loops back a configurable number of transfers.
33725d80151SAndrzej Pietrasiewicz	  Sourcesink function either sinks and sources bulk data.
338c0501f47SAndrzej Pietrasiewicz	  It also implements control requests, for "chapter 9" conformance.
339c0501f47SAndrzej Pietrasiewicz	  Make this be the first driver you try using on top of any new
340c0501f47SAndrzej Pietrasiewicz	  USB peripheral controller driver.  Then you can use host-side
341c0501f47SAndrzej Pietrasiewicz	  test software, like the "usbtest" driver, to put your hardware
342c0501f47SAndrzej Pietrasiewicz	  and its driver through a basic set of functional tests.
343c0501f47SAndrzej Pietrasiewicz
344b658499fSAndrzej Pietrasiewiczconfig USB_CONFIGFS_F_FS
345b658499fSAndrzej Pietrasiewicz	boolean "Function filesystem (FunctionFS)"
346b658499fSAndrzej Pietrasiewicz	depends on USB_CONFIGFS
347b658499fSAndrzej Pietrasiewicz	select USB_F_FS
348b658499fSAndrzej Pietrasiewicz	help
349b658499fSAndrzej Pietrasiewicz	  The Function Filesystem (FunctionFS) lets one create USB
350b658499fSAndrzej Pietrasiewicz	  composite functions in user space in the same way GadgetFS
351b658499fSAndrzej Pietrasiewicz	  lets one create USB gadgets in user space.  This allows creation
352b658499fSAndrzej Pietrasiewicz	  of composite gadgets such that some of the functions are
353b658499fSAndrzej Pietrasiewicz	  implemented in kernel space (for instance Ethernet, serial or
354b658499fSAndrzej Pietrasiewicz	  mass storage) and other are implemented in user space.
355b658499fSAndrzej Pietrasiewicz
3568443f2d2SAndrzej Pietrasiewiczsource "drivers/usb/gadget/legacy/Kconfig"
3571da177e4SLinus Torvalds
3581da177e4SLinus Torvaldsendchoice
3591da177e4SLinus Torvalds
360b75be4abSDenis Chengendif # USB_GADGET
361