Skip to content

Commit fd40333

Browse files
authored
Add interrupt handler functions for DWC2 ESP32
1 parent 2056a52 commit fd40333

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

patches/dwc2_esp32_h.diff

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
diff --git a/src/portable/synopsys/dwc2/dwc2_esp32.h b/src/portable/synopsys/dwc2/dwc2_esp32.h
2+
index 49b8c54cb..8b5e99741 100644
3+
--- a/src/portable/synopsys/dwc2/dwc2_esp32.h
4+
+++ b/src/portable/synopsys/dwc2/dwc2_esp32.h
5+
@@ -70,11 +70,13 @@ static void dwc2_int_handler_wrap(void* arg) {
6+
const tusb_role_t role = (tusb_role_t) tu_u16_high((uint16_t)(uintptr_t)arg);
7+
#if CFG_TUD_ENABLED
8+
if (role == TUSB_ROLE_DEVICE) {
9+
+ void dcd_int_handler(uint8_t rhport);
10+
dcd_int_handler(rhport);
11+
}
12+
#endif
13+
#if CFG_TUH_ENABLED && !CFG_TUH_MAX3421
14+
if (role == TUSB_ROLE_HOST) {
15+
+ void hcd_int_handler(uint8_t rhport, bool in_isr);
16+
hcd_int_handler(rhport, true);
17+
}
18+
#endif

0 commit comments

Comments
 (0)