usb_claim_interface claims the interface with the Operating System. The interface parameter is the value as specified in the descriptor field bInterfaceNumber. Returns 0 on success or < 0 on error.
Must be called!: usb_claim_interface must be called before you perform any operations related to this interface (like usb_set_altinterface, usb_bulk_write, etc).
Table 1. Return Codes
| code | description |
|---|---|
| -EBUSY | Interface is not available to be claimed |
| -ENOMEM | Insufficient memory |