From b53ba2e4b47bc8edb95ad508400ced779b67c7f9 Mon Sep 17 00:00:00 2001 From: xj Date: Tue, 13 Aug 2024 19:31:36 -0700 Subject: [PATCH] Interrupt function --- .../drivers/usb/components/port/xhci/usb_hc_xhci.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Ubiquitous/XiZi_AIoT/services/drivers/usb/components/port/xhci/usb_hc_xhci.c b/Ubiquitous/XiZi_AIoT/services/drivers/usb/components/port/xhci/usb_hc_xhci.c index 7633a3ec8..8ccf71ace 100644 --- a/Ubiquitous/XiZi_AIoT/services/drivers/usb/components/port/xhci/usb_hc_xhci.c +++ b/Ubiquitous/XiZi_AIoT/services/drivers/usb/components/port/xhci/usb_hc_xhci.c @@ -612,6 +612,10 @@ int xhci_usb_hc_init(uint32_t id){ goto err_open; } + if((rc = create_xhci_intr_service(xhci) < 0 )){ + goto err_open; + } + err_open: usb_osal_leave_critical_section(flag); return rc; @@ -1035,12 +1039,14 @@ void XHCI_USBH_IRQHandler(void *param){ uint32_t usbsts; uint32_t runtime; + id = (intptr_t)param; if(id < 0 || id >= CONFIG_USBHOST_XHCI_NUM){ return; } + xhci = &xhci_host[id]; USB_ASSERT(xhci); @@ -1060,6 +1066,10 @@ void XHCI_USBH_IRQHandler(void *param){ int IPC_DO_SERVE_FUNC(Ipc_xhci_intr)(void* ignore) { printf("TEST_SW_HDLR: In %s()\n", __func__); + intptr_t id; + + id = 0; + XHCI_USBH_IRQHandler((void *)id); return 0; }