1. NAME

usb_autopm_get_interface - increment a USB interfaceAqs PM-usage counter

2. SYNOPSIS

int usb_autopm_get_interface(struct usb_interface *  intf );

3. ARGUMENTS

intf
    the usb_interface whose counter should be incremented

4. DESCRIPTION

This routine should be called by an interface driver when it wants to use intf and needs to guarantee that it is not suspended. In addition, the routine prevents intf from being autosuspended subsequently. (Note that this will not prevent suspend events originating in the PM core.) This prevention will persist until usb_autopm_put_interface is called or intf is unbound. A typical example would be a character-device driver when its device file is opened.

intfAqs usage counter is incremented to prevent subsequent autosuspends. However if the autoresume fails then the counter is re-decremented.

This routine can run only in process context.

5. COPYRIGHT