Lines Matching refs:gadget
5 Linux USB gadget configured through configfs
20 A gadget is seen by its host as a set of configurations, each of which contains
21 a number of interfaces which, from the gadget's perspective, are known as
26 Creating a gadget means deciding what configurations there will be
33 It also describes how configfs integration into gadget is designed.
62 For each gadget to be created its corresponding directory must be created:
64 $ mkdir $CONFIGFS_HOME/usb_gadget/<gadget name>
76 Each gadget needs to have its vendor id <VID> and product id <PID> specified:
81 A gadget also needs its serial number, manufacturer and product strings.
96 Each gadget will consist of a number of configurations, their corresponding
126 The gadget will provide some functions, for each function its corresponding
143 Please refer to Documentation/ABI/*/configfs-usb-gadget* for more information.
164 5. Enabling the gadget
167 All the above steps serve the purpose of composing the gadget of
203 Such a gadget must be finally enabled so that the USB host can enumerate it.
204 In order to enable the gadget it must be bound to a UDC (USB Device Controller).
214 6. Disabling the gadget
271 Remove strings directories in the gadget
279 and finally remove the gadget:
282 $ rmdir <gadget name>
355 1. A gadget has its config group, which has some attributes (idVendor,
364 gadget's UDC attribute is written to, which means binding the gadget
365 to the UDC. The code in drivers/usb/gadget/configfs.c iterates over
367 functions and binds them. This way the whole gadget is bound.
369 3. The file drivers/usb/gadget/configfs.c contains code for
371 - gadget's config_group
372 - gadget's default groups (configs, functions, strings)
377 in the functions implementation files drivers/usb/gadget/f_*.c.
384 after a gadget is disabled and torn down, the modules remain loaded.