summaryrefslogtreecommitdiff
path: root/shared/tinyusb
diff options
context:
space:
mode:
authorAndrew Leech <andrew.leech@planetinnovation.com.au>2024-07-31 21:40:05 +1000
committerDamien George <damien@micropython.org>2024-10-07 11:06:57 +1100
commit548f88d2bd254f1328014a303f8bf602a0646421 (patch)
tree3b6cb925e916c239f32c721bb3f3a1f8f6d61aaa /shared/tinyusb
parent11bc7d0fc1074b01aaddc325209a281ee9acbba4 (diff)
shared/tinyusb: Wake main task if needed at end of USB ISR.
Signed-off-by: Andrew Leech <andrew@alelec.net>
Diffstat (limited to 'shared/tinyusb')
-rw-r--r--shared/tinyusb/mp_usbd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/shared/tinyusb/mp_usbd.c b/shared/tinyusb/mp_usbd.c
index 436314dcd..7ccfa7018 100644
--- a/shared/tinyusb/mp_usbd.c
+++ b/shared/tinyusb/mp_usbd.c
@@ -24,7 +24,7 @@
* THE SOFTWARE.
*/
-#include "py/mpconfig.h"
+#include "py/mphal.h"
#if MICROPY_HW_ENABLE_USBDEV
@@ -55,6 +55,7 @@ extern void __real_dcd_event_handler(dcd_event_t const *event, bool in_isr);
TU_ATTR_FAST_FUNC void __wrap_dcd_event_handler(dcd_event_t const *event, bool in_isr) {
__real_dcd_event_handler(event, in_isr);
mp_usbd_schedule_task();
+ mp_hal_wake_main_task_from_isr();
}
TU_ATTR_FAST_FUNC void mp_usbd_schedule_task(void) {