This commit is contained in:
hathach 2020-04-15 13:53:50 +07:00
parent 3bfb402d8c
commit 93ffe317b2
No known key found for this signature in database
GPG Key ID: 2FA891220FBFD581
1 changed files with 0 additions and 22 deletions

View File

@ -241,8 +241,6 @@ static osal_queue_t _usbd_q;
// Prototypes
//--------------------------------------------------------------------+
static void mark_interface_endpoint(uint8_t ep2drv[8][2], uint8_t const* p_desc, uint16_t desc_len, uint8_t driver_id);
//static uint8_t find_driver_id(tusb_desc_interface_t const * desc_itf);
static bool process_control_request(uint8_t rhport, tusb_control_request_t const * p_request);
static bool process_set_config(uint8_t rhport, uint8_t cfg_num);
static bool process_get_descriptor(uint8_t rhport, tusb_control_request_t const * p_request);
@ -772,26 +770,6 @@ static bool process_set_config(uint8_t rhport, uint8_t cfg_num)
return true;
}
#if 0
// Helper to find class driver id for an interface
// return 0xFF if not found
static uint8_t find_driver_id(tusb_desc_interface_t const * desc_itf)
{
for (uint8_t drv_id = 0; drv_id < USBD_CLASS_DRIVER_COUNT; drv_id++)
{
usbd_class_driver_t const *driver = &_usbd_driver[drv_id];
if ( (driver->class_code == desc_itf->bInterfaceClass) && // match class code
(driver->subclass == desc_itf->bInterfaceSubClass || driver->all_subclass ) && // match subclass or driver support all
(driver->protocol == desc_itf->bInterfaceProtocol || driver->all_protocol)) // match protocol or driver support all
{
return drv_id;
}
}
return DRVID_INVALID;
}
#endif
// Helper marking endpoint of interface belongs to class driver
static void mark_interface_endpoint(uint8_t ep2drv[8][2], uint8_t const* p_desc, uint16_t desc_len, uint8_t driver_id)
{