From: Frank Mori Hess Date: Mon, 17 Feb 2003 18:01:33 +0000 (+0000) Subject: use dma chan 0 X-Git-Tag: r0_7_67x~102 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=bc8c4ca05bf7dccf30221c58f6679837d74720bf;p=comedi.git use dma chan 0 --- diff --git a/comedi/drivers/gsc_hpdi.c b/comedi/drivers/gsc_hpdi.c index d8430e00..904fe3cd 100644 --- a/comedi/drivers/gsc_hpdi.c +++ b/comedi/drivers/gsc_hpdi.c @@ -838,7 +838,10 @@ static void handle_interrupt(int irq, void *d, struct pt_regs *regs) writeb((dma0_status & PLX_DMA_EN_BIT) | PLX_CLEAR_DMA_INTR_BIT, priv(dev)->plx9080_iobase + PLX_DMA0_CS_REG); DEBUG_PRINT("dma0 status 0x%x\n", dma0_status); - + if(dma0_status & PLX_DMA_EN_BIT) + { + drain_dma_buffers(dev, 0); + } DEBUG_PRINT(" cleared dma ch0 interrupt\n"); } comedi_spin_unlock_irqrestore( &dev->spinlock, flags ); @@ -848,14 +851,9 @@ static void handle_interrupt(int irq, void *d, struct pt_regs *regs) dma1_status = readb(priv(dev)->plx9080_iobase + PLX_DMA1_CS_REG); if(plx_status & ICS_DMA1_A) // XXX { // dma chan 1 interrupt - // XXX possible race writeb((dma1_status & PLX_DMA_EN_BIT) | PLX_CLEAR_DMA_INTR_BIT, priv(dev)->plx9080_iobase + PLX_DMA1_CS_REG); DEBUG_PRINT("dma1 status 0x%x\n", dma1_status); - if(dma1_status & PLX_DMA_EN_BIT) - { - drain_dma_buffers(dev, 1); - } DEBUG_PRINT(" cleared dma ch1 interrupt\n"); } comedi_spin_unlock_irqrestore( &dev->spinlock, flags );