diff options
Diffstat (limited to 'tinyusb/class')
| -rw-r--r-- | tinyusb/class/cdc_host.c | 4 | ||||
| -rw-r--r-- | tinyusb/class/cdc_rndis_host.c | 5 |
2 files changed, 7 insertions, 2 deletions
diff --git a/tinyusb/class/cdc_host.c b/tinyusb/class/cdc_host.c index 0e97c5d9a..2b81b9ab6 100644 --- a/tinyusb/class/cdc_host.c +++ b/tinyusb/class/cdc_host.c @@ -204,8 +204,8 @@ tusb_error_t cdch_open_subtask(uint8_t dev_addr, tusb_descriptor_interface_t con { OSAL_SUBTASK_INVOKED_AND_WAIT( rndish_open_subtask(dev_addr, p_cdc), error ); } - else -// if ( TUSB_ERROR_NONE != error ) // device is not an rndis + + if ( !(0xff == p_cdc->interface_protocol && TUSB_ERROR_NONE == error) ) // device is not an rndis #endif // FIXME mounted class flag is not set yet diff --git a/tinyusb/class/cdc_rndis_host.c b/tinyusb/class/cdc_rndis_host.c index 024329b4b..585cf7d42 100644 --- a/tinyusb/class/cdc_rndis_host.c +++ b/tinyusb/class/cdc_rndis_host.c @@ -116,6 +116,11 @@ tusb_error_t rndish_open_subtask(uint8_t dev_addr, cdch_data_t *p_cdc) error ); + if ( TUSB_ERROR_NONE != error) + { + SUBTASK_EXIT(error); + } + if ( tusbh_cdc_rndis_mounted_cb ) { tusbh_cdc_rndis_mounted_cb(dev_addr); |
