linux-yocto/Documentation/ABI/testing/configfs-usb-gadget-ffs
Peter Korsgaard 43a029724d usb: gadget: f_fs: expose ready state in configfs
When a USB gadget is configured through configfs with 1 or more f_fs
functions, then the logic setting up the gadget configuration has to wait
until the user space code (typically separate applications) responsible for
those functions have written their descriptors before the gadget can be
activated.

The f_fs instance already knows if this has been done, so expose it through
a "ready" attribute in configfs for easier synchronization.

Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Link: https://lore.kernel.org/r/20240126203208.2482573-1-peter@korsgaard.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-01-27 17:39:21 -08:00

594 B

What: /config/usb-gadget/gadget/functions/ffs.name Date: Nov 2013 KernelVersion: 3.13 Description: The purpose of this directory is to create and remove it.

	A corresponding USB function instance is created/removed.

	All attributes are read only:

	=============	============================================
	ready		1 if the function is ready to be used, E.G.
			if userspace has written descriptors and
			strings to ep0, so the gadget can be
			enabled - 0 otherwise.
	=============	============================================

	All other parameters are set through FunctionFS.