/* Don't call this function unless you are bound to the intf interface or you have locked the device!  */
struct usb_host_virt_interface* usb_altnum_to_altsetting(struct usb_interface *intf, s32 altnum)
/* Don't call this function unless you are bound to the intf interface or you have locked the device!  */
struct usb_host_virt_interface* usb_altnum_to_altsetting(struct usb_interface *intf, s32 altnum)
{
    int i;
    for (i = 0; i < intf->num_altsetting; i++)
    {
        if (intf->altsetting[i].desc.bAlternateSetting == altnum)
        {
            return &intf->altsetting[i];
        }
    }
    return NULL;
}