static irqreturn_t dwc_otg_common_irq(int _irq, void *dev) { struct dwc_otg_device *dwc_dev = dev; int retval; spin_lock(&dwc_dev->lock); retval = dwc_otg_handle_common_intr(dwc_dev->core_if); spin_unlock(&dwc_dev->lock); return IRQ_RETVAL(retval); }
/* * This function must be registered as a interrupt handler after calling the * driver_init() function. */ void usb_ISR(void) { /* * FIXME: we shall be able to detect USB reset here with resetdet field * or is it host only */ gintsts_data_t gintsts; __DWC_WARN("USB ISR! - enter\n"); do { dwc_otg_handle_common_intr(dwc_otg_device); dwc_otg_pcd_handle_intr(dwc_otg_device->pcd); gintsts.d32 = dwc_otg_read_core_intr(dwc_otg_device->core_if); __DWC_WARN("USB ISR! - gintsts: %d\n", gintsts.d32); } while (gintsts.d32 != 0); __DWC_WARN("USB ISR! - exit\n"); }