OMAP: sDMA: DMA : DMA spurious IRQ in shared usage
diff mbox

Message ID
State Accepted
Commit 04110caa6e1c5f92225c34a62d1bd7b6d276b85e
Delegated to: Tony Lindgren
Headers show

Commit Message

Santosh Shilimkar Feb. 4, 2009, 9:12 a.m. UTC
Here is the second patch which fixes the spurious irq issue on sDMA when used by two software modules with independent interrupt lines.

From: Santosh Shilimkar <>

    This fixes the spurious interrupt issue on a DMA channel.
    In OMAP sDMA, contrast to the SDMA.DMA4_CSRi registers, the 
    SDMA.DMA4_IRQSTATUS_Lj registers are updated regardless of 
    the corresponding bits in the SDMA.DMA4_IRQENABLE_Lj registers.
    Since there are four sDMA interrupt lines and if more than one
    line is actively used by two concurrently running sDMA softwares
    modules,then the spurious interrupt can be observed on the other
    Fix in this patch will only dispatch the relevant and enabled
    interrupts on a particular line thus perevting spurious IRQ.

Signed-off-by: Santosh Shilimkar <>
Acked By: Nishant Kamat <>
cc: Tony Lindgren <>

 arch/arm/plat-omap/dma.c |    8 +++++---
 1 files changed, 5 insertions(+), 3 deletions(-)

To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to
More majordomo info at


Tony Lindgren Feb. 27, 2009, 7:38 p.m. UTC | #1
This patch has been applied to the linux-omap
by youw fwiendly patch wobot.

Commit: 04110caa6e1c5f92225c34a62d1bd7b6d276b85e



To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to
More majordomo info at

diff mbox

Index: omapkernel/arch/arm/plat-omap/dma.c
--- omapkernel.orig/arch/arm/plat-omap/dma.c	2009-02-04 13:07:51.000000000 +0530
+++ omapkernel/arch/arm/plat-omap/dma.c	2009-02-04 14:00:38.709913959 +0530
@@ -1954,7 +1954,7 @@  static int omap2_dma_handle_ch(int ch)
 /* STATUS register count is from 1-32 while our is 0-31 */
 static irqreturn_t omap2_dma_irq_handler(int irq, void *dev_id)
-	u32 val;
+	u32 val, enable_reg;
 	int i;
 	val = dma_read(IRQSTATUS_L0);
@@ -1963,6 +1963,8 @@  static irqreturn_t omap2_dma_irq_handler
 			printk(KERN_WARNING "Spurious DMA IRQ\n");
 		return IRQ_HANDLED;
+	enable_reg = dma_read(IRQENABLE_L0);
+	val &= enable_reg; /* Dispatch only relevant interrupts */
 	for (i = 0; i < dma_lch_count && val != 0; i++) {
 		if (val & 1)