port: hpmicro: add USBH_USE_CUSTOM_ISR add USBD_USE_CUSTOM_ISR to control isr

- add USBH_USE_CUSTOM_ISR add USBD_USE_CUSTOM_ISR to control isr

Signed-off-by: Zhihong Chen <zhihong.chen@hpmicro.com>
This commit is contained in:
Zhihong Chen
2024-08-21 17:35:52 +08:00
committed by sakumisu
parent e8b22163bb
commit 2726e2e7b6
2 changed files with 9 additions and 1 deletions

View File

@@ -82,6 +82,8 @@ uint8_t usbh_get_port_speed(struct usbh_bus *bus, const uint8_t port)
return 0;
}
#if !defined(USBH_USE_CUSTOM_ISR) || !USBH_USE_CUSTOM_ISR
extern void USBH_IRQHandler(uint8_t busid);
void isr_usbh0(void)
@@ -97,3 +99,5 @@ void isr_usbh1(void)
}
SDK_DECLARE_EXT_ISR_M(IRQn_USB1, isr_usbh1)
#endif
#endif

View File

@@ -359,6 +359,8 @@ void USBD_IRQHandler(uint8_t busid)
}
}
#if !defined(USBD_USE_CUSTOM_ISR) || !USBD_USE_CUSTOM_ISR
void isr_usbd0(void)
{
USBD_IRQHandler(_dcd_busid[0]);
@@ -371,4 +373,6 @@ void isr_usbd1(void)
USBD_IRQHandler(_dcd_busid[1]);
}
SDK_DECLARE_EXT_ISR_M(IRQn_USB1, isr_usbd1)
#endif
#endif
#endif