diff options
| author | sakumisu <[email protected]> | 2025-06-03 17:31:31 +0800 |
|---|---|---|
| committer | sakumisu <[email protected]> | 2025-06-03 22:43:35 +0800 |
| commit | bff8a632a926cf976c3bbb18097f8a70d7cd9b93 (patch) | |
| tree | d2219f3e1674f78b8cc69bae6aa18df06cac8be5 /class | |
| parent | a8bf2687bde6ff5eb8e5b501226cb21945a7f8df (diff) | |
feat(class): add usb_osal_thread_schedule_other to allow the applications which use the struct usbh_xxx to exit properly before free struct usbh_xxx
Signed-off-by: sakumisu <[email protected]>
Diffstat (limited to 'class')
| -rw-r--r-- | class/audio/usbh_audio.c | 1 | ||||
| -rw-r--r-- | class/cdc/usbh_cdc_acm.c | 1 | ||||
| -rw-r--r-- | class/cdc/usbh_cdc_ecm.c | 1 | ||||
| -rw-r--r-- | class/cdc/usbh_cdc_ncm.c | 1 | ||||
| -rw-r--r-- | class/hid/usbh_hid.c | 1 | ||||
| -rw-r--r-- | class/msc/usbh_msc.c | 1 | ||||
| -rw-r--r-- | class/vendor/net/usbh_asix.c | 1 | ||||
| -rw-r--r-- | class/vendor/net/usbh_rtl8152.c | 1 | ||||
| -rw-r--r-- | class/vendor/serial/usbh_ch34x.c | 1 | ||||
| -rw-r--r-- | class/vendor/serial/usbh_cp210x.c | 1 | ||||
| -rw-r--r-- | class/vendor/serial/usbh_ftdi.c | 1 | ||||
| -rw-r--r-- | class/vendor/serial/usbh_pl2303.c | 1 | ||||
| -rw-r--r-- | class/vendor/wifi/usbh_bl616.c | 1 | ||||
| -rw-r--r-- | class/vendor/xbox/usbh_xbox.c | 1 | ||||
| -rw-r--r-- | class/video/usbh_video.c | 1 | ||||
| -rw-r--r-- | class/wireless/usbh_bluetooth.c | 1 | ||||
| -rw-r--r-- | class/wireless/usbh_rndis.c | 1 |
17 files changed, 17 insertions, 0 deletions
diff --git a/class/audio/usbh_audio.c b/class/audio/usbh_audio.c index 63b0b857..4aed30fe 100644 --- a/class/audio/usbh_audio.c +++ b/class/audio/usbh_audio.c @@ -594,6 +594,7 @@ static int usbh_audio_ctrl_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister Audio Class:%s\r\n", hport->config.intf[intf].devname); usbh_audio_stop(audio_class); } diff --git a/class/cdc/usbh_cdc_acm.c b/class/cdc/usbh_cdc_acm.c index 53666b32..2fc54eed 100644 --- a/class/cdc/usbh_cdc_acm.c +++ b/class/cdc/usbh_cdc_acm.c @@ -193,6 +193,7 @@ static int usbh_cdc_acm_disconnect(struct usbh_hubport *hport, uint8_t intf) #endif if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister CDC ACM Class:%s\r\n", hport->config.intf[intf].devname); usbh_cdc_acm_stop(cdc_acm_class); } diff --git a/class/cdc/usbh_cdc_ecm.c b/class/cdc/usbh_cdc_ecm.c index 286af231..094ea14f 100644 --- a/class/cdc/usbh_cdc_ecm.c +++ b/class/cdc/usbh_cdc_ecm.c @@ -221,6 +221,7 @@ static int usbh_cdc_ecm_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister CDC ECM Class:%s\r\n", hport->config.intf[intf].devname); usbh_cdc_ecm_stop(cdc_ecm_class); } diff --git a/class/cdc/usbh_cdc_ncm.c b/class/cdc/usbh_cdc_ncm.c index 7e35da36..b7c89f3d 100644 --- a/class/cdc/usbh_cdc_ncm.c +++ b/class/cdc/usbh_cdc_ncm.c @@ -239,6 +239,7 @@ static int usbh_cdc_ncm_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister CDC NCM Class:%s\r\n", hport->config.intf[intf].devname); usbh_cdc_ncm_stop(cdc_ncm_class); } diff --git a/class/hid/usbh_hid.c b/class/hid/usbh_hid.c index cb407f54..5c400c7b 100644 --- a/class/hid/usbh_hid.c +++ b/class/hid/usbh_hid.c @@ -299,6 +299,7 @@ int usbh_hid_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister HID Class:%s\r\n", hport->config.intf[intf].devname); usbh_hid_stop(hid_class); } diff --git a/class/msc/usbh_msc.c b/class/msc/usbh_msc.c index 88c90b0b..fe91a5bf 100644 --- a/class/msc/usbh_msc.c +++ b/class/msc/usbh_msc.c @@ -342,6 +342,7 @@ static int usbh_msc_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister MSC Class:%s\r\n", hport->config.intf[intf].devname); usbh_msc_stop(msc_class); } diff --git a/class/vendor/net/usbh_asix.c b/class/vendor/net/usbh_asix.c index 60b64472..981c5067 100644 --- a/class/vendor/net/usbh_asix.c +++ b/class/vendor/net/usbh_asix.c @@ -638,6 +638,7 @@ static int usbh_asix_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister ASIX Class:%s\r\n", hport->config.intf[intf].devname); usbh_asix_stop(asix_class); } diff --git a/class/vendor/net/usbh_rtl8152.c b/class/vendor/net/usbh_rtl8152.c index 60fec839..9c4b6570 100644 --- a/class/vendor/net/usbh_rtl8152.c +++ b/class/vendor/net/usbh_rtl8152.c @@ -2121,6 +2121,7 @@ static int usbh_rtl8152_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister rtl8152 Class:%s\r\n", hport->config.intf[intf].devname); usbh_rtl8152_stop(rtl8152_class); } diff --git a/class/vendor/serial/usbh_ch34x.c b/class/vendor/serial/usbh_ch34x.c index a6908345..3941d47d 100644 --- a/class/vendor/serial/usbh_ch34x.c +++ b/class/vendor/serial/usbh_ch34x.c @@ -311,6 +311,7 @@ static int usbh_ch34x_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister CH34X Class:%s\r\n", hport->config.intf[intf].devname); usbh_ch34x_stop(ch34x_class); } diff --git a/class/vendor/serial/usbh_cp210x.c b/class/vendor/serial/usbh_cp210x.c index f3b0d461..f58350e6 100644 --- a/class/vendor/serial/usbh_cp210x.c +++ b/class/vendor/serial/usbh_cp210x.c @@ -260,6 +260,7 @@ static int usbh_cp210x_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister CP210X Class:%s\r\n", hport->config.intf[intf].devname); usbh_cp210x_stop(cp210x_class); } diff --git a/class/vendor/serial/usbh_ftdi.c b/class/vendor/serial/usbh_ftdi.c index b45f4d52..6bc19b20 100644 --- a/class/vendor/serial/usbh_ftdi.c +++ b/class/vendor/serial/usbh_ftdi.c @@ -440,6 +440,7 @@ static int usbh_ftdi_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister FTDI Class:%s\r\n", hport->config.intf[intf].devname); usbh_ftdi_stop(ftdi_class); } diff --git a/class/vendor/serial/usbh_pl2303.c b/class/vendor/serial/usbh_pl2303.c index 35574cdc..ece32538 100644 --- a/class/vendor/serial/usbh_pl2303.c +++ b/class/vendor/serial/usbh_pl2303.c @@ -375,6 +375,7 @@ static int usbh_pl2303_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister PL2303 Class:%s\r\n", hport->config.intf[intf].devname); usbh_pl2303_stop(pl2303_class); } diff --git a/class/vendor/wifi/usbh_bl616.c b/class/vendor/wifi/usbh_bl616.c index 059086be..e44df5bd 100644 --- a/class/vendor/wifi/usbh_bl616.c +++ b/class/vendor/wifi/usbh_bl616.c @@ -337,6 +337,7 @@ static int usbh_bl616_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister BL616 WIFI Class:%s\r\n", hport->config.intf[intf].devname); usbh_bl616_stop(bl616_class); } diff --git a/class/vendor/xbox/usbh_xbox.c b/class/vendor/xbox/usbh_xbox.c index 0c3339c9..364ca27c 100644 --- a/class/vendor/xbox/usbh_xbox.c +++ b/class/vendor/xbox/usbh_xbox.c @@ -86,6 +86,7 @@ int usbh_xbox_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister XBOX Class:%s\r\n", hport->config.intf[intf].devname); usbh_xbox_stop(xbox_class); } diff --git a/class/video/usbh_video.c b/class/video/usbh_video.c index cd8e5e65..077b6bb9 100644 --- a/class/video/usbh_video.c +++ b/class/video/usbh_video.c @@ -483,6 +483,7 @@ static int usbh_video_ctrl_disconnect(struct usbh_hubport *hport, uint8_t intf) } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister Video Class:%s\r\n", hport->config.intf[intf].devname); usbh_video_stop(video_class); } diff --git a/class/wireless/usbh_bluetooth.c b/class/wireless/usbh_bluetooth.c index 59c0586f..af7167c0 100644 --- a/class/wireless/usbh_bluetooth.c +++ b/class/wireless/usbh_bluetooth.c @@ -134,6 +134,7 @@ static int usbh_bluetooth_disconnect(struct usbh_hubport *hport, uint8_t intf) // } #endif if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister Bluetooth Class:%s\r\n", hport->config.intf[intf].devname); usbh_bluetooth_stop(bluetooth_class); } diff --git a/class/wireless/usbh_rndis.c b/class/wireless/usbh_rndis.c index 8eef39dd..b6e43a76 100644 --- a/class/wireless/usbh_rndis.c +++ b/class/wireless/usbh_rndis.c @@ -438,6 +438,7 @@ static int usbh_rndis_disconnect(struct usbh_hubport *hport, uint8_t intf) // } if (hport->config.intf[intf].devname[0] != '\0') { + usb_osal_thread_schedule_other(); USB_LOG_INFO("Unregister RNDIS Class:%s\r\n", hport->config.intf[intf].devname); usbh_rndis_stop(rndis_class); } |
