1. NAME

usb_add_function - add a function to a configuration

2. SYNOPSIS

int usb_add_function(struct usb_configuration *  config , struct usb_function *  function );

3. ARGUMENTS

config
    the configuration

function
    the function being added

4. CONTEXT

single threaded during gadget setup

5. DESCRIPTION

After initialization, each configuration must have one or more functions added to it. Adding a function involves calling its bind() method to allocate resources such as interface and string identifiers and endpoints.

This function returns the value of the functionAqs bind, which is zero for success else a negative errno value.

6. AUTHOR

David Brownell <>
    Author.

7. COPYRIGHT