do not check if device is closed
This commit is contained in:
@@ -126,10 +126,6 @@ int usbh_audio_close(struct usbh_audio *audio_class, const char *name)
|
||||
uint8_t intf = 0xff;
|
||||
uint8_t altsetting = 1;
|
||||
|
||||
if (audio_class->is_opened == false) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
for (size_t i = 0; i < audio_class->module_num; i++) {
|
||||
if (strcmp(name, audio_class->module[i].name) == 0) {
|
||||
intf = audio_class->module[i].data_intf;
|
||||
|
||||
@@ -251,10 +251,6 @@ int usbh_video_close(struct usbh_video *video_class)
|
||||
|
||||
USB_LOG_INFO("Close video device\r\n");
|
||||
|
||||
if (video_class->is_opened == false) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
video_class->is_opened = false;
|
||||
|
||||
if (video_class->isoin) {
|
||||
|
||||
Reference in New Issue
Block a user