|
@@ -902,7 +902,7 @@ static irqreturn_t s3c2410_udc_irq(int dummy, void *_dev)
|
|
int pwr_reg;
|
|
int pwr_reg;
|
|
int ep0csr;
|
|
int ep0csr;
|
|
int i;
|
|
int i;
|
|
- u32 idx;
|
|
|
|
|
|
+ u32 idx, idx2;
|
|
unsigned long flags;
|
|
unsigned long flags;
|
|
|
|
|
|
spin_lock_irqsave(&dev->lock, flags);
|
|
spin_lock_irqsave(&dev->lock, flags);
|
|
@@ -1017,6 +1017,20 @@ static irqreturn_t s3c2410_udc_irq(int dummy, void *_dev)
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+ /* what else causes this interrupt? a receive! who is it? */
|
|
|
|
+ if (!usb_status && !usbd_status && !pwr_reg && !ep0csr) {
|
|
|
|
+ for (i = 1; i < S3C2410_ENDPOINTS; i++) {
|
|
|
|
+ idx2 = udc_read(S3C2410_UDC_INDEX_REG);
|
|
|
|
+ udc_write(i, S3C2410_UDC_INDEX_REG);
|
|
|
|
+
|
|
|
|
+ if (udc_read(S3C2410_UDC_OUT_CSR1_REG) & 0x1)
|
|
|
|
+ s3c2410_udc_handle_ep(&dev->ep[i]);
|
|
|
|
+
|
|
|
|
+ /* restore index */
|
|
|
|
+ udc_write(idx2, S3C2410_UDC_INDEX_REG);
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
dprintk(DEBUG_VERBOSE, "irq: %d s3c2410_udc_done.\n", IRQ_USBD);
|
|
dprintk(DEBUG_VERBOSE, "irq: %d s3c2410_udc_done.\n", IRQ_USBD);
|
|
|
|
|
|
/* Restore old index */
|
|
/* Restore old index */
|