Lines Matching defs:function

44  * from one or more "function" drivers, one or more "configuration"
56 * function_descriptors() - get function descriptors for speed
57 * @f: the function
136 * @f: usb function
142 * This function chooses the right descriptors for a given
148 * Note: the supplied function should hold all the descriptors
274 * @f: usb function
279 * This function chooses the right descriptors for a given
285 * Note: the supplied function should hold all the descriptors
297 * usb_add_function() - add a function to a configuration
299 * @function: the function being added
303 * functions added to it. Adding a function involves calling its @bind()
307 * This function returns the value of the function's bind(), which is
311 struct usb_function *function)
316 function->name, function,
319 if (!function->set_alt || !function->disable)
322 function->config = config;
323 list_add_tail(&function->list, &config->functions);
325 if (function->bind_deactivated) {
326 value = usb_function_deactivate(function);
331 /* REVISIT *require* function->bind? */
332 if (function->bind) {
333 value = function->bind(config, function);
335 list_del(&function->list);
336 function->config = NULL;
343 * as full speed ... it's the function drivers that will need
346 if (!config->fullspeed && function->fs_descriptors)
348 if (!config->highspeed && function->hs_descriptors)
350 if (!config->superspeed && function->ss_descriptors)
352 if (!config->superspeed_plus && function->ssp_descriptors)
358 function->name, function, value);
379 * usb_function_deactivate - prevent function and gadget enumeration
380 * @function: the function that isn't yet ready to respond
397 int usb_function_deactivate(struct usb_function *function)
399 struct usb_composite_dev *cdev = function->config->cdev;
419 * usb_function_activate - allow function and gadget enumeration
420 * @function: function on which usb_function_activate() was called
428 int usb_function_activate(struct usb_function *function)
430 struct usb_composite_dev *cdev = function->config->cdev;
455 * @function: function handling the interface
459 * allocate new interface IDs. The function driver will then store that
476 struct usb_function *function)
481 config->interface[id] = function;
490 * usb_func_wakeup - sends function wake notification to the host.
491 * @func: function that sends the remote wakeup notification.
494 * functions are put in function suspend state and armed for function
495 * remote wakeup. On completion, function wake notification is sent. If
521 ERROR(func->config->cdev, "Invalid function\n");
594 /* add each function's descriptors */
721 * This function generates the BOS (Binary Device Object)
998 * Record which endpoints are used by the function. This is used
1000 * function's setup callback instead of the current
1093 * @bind: the configuration's bind function
1099 * This function returns the value of the configuration's @bind(), which
1134 DBG(cdev, "unbind function '%s'/%p\n",
1201 * Drivers must call usb_gadget_disconnect before calling this function
1486 * This function will create a deep copy of usb_gadget_strings and usb_string
1582 * REVIST The same ep0 requests are shared with function drivers
1773 * housekeeping for the gadget function we're implementing. Most of
1774 * the work is in config and function specific setup.
1803 /* partial re-init of the response message; the function or the
1936 /* function drivers must handle get/set altsetting */
1996 * Note: function driver should supply such cb only for the
1997 * first interface of the function
2029 * only for the first interface of the function
2063 * Handle cases where host sends function resume
2262 /* try the only function in the current config */
2557 * serial number), register function drivers, potentially update
2625 * Check for func_suspended flag to see if the function is
2677 * This function is used to register drivers using the composite driver
2700 gadget_driver->function = (char *) driver->name;
2712 * This function is used to unregister drivers using the composite
2725 * This function must be called by the USB function driver to continue
2727 * delay the data/status stages. A USB function's setup handler (e.g. set_alt())