diff options
author | H Hartley Sweeten <hsweeten@visionengravers.com> | 2014-03-08 00:31:46 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-03-17 20:55:57 (GMT) |
commit | 52037a0d520e988e3287b28bc767b58ddc66ad94 (patch) | |
tree | ab4f0e2df0acbf774415ff14bebe5fa2dcf15f44 /drivers | |
parent | fb6aa25009ff7c8ec65673d5a34d7191dc6c5894 (diff) | |
download | linux-52037a0d520e988e3287b28bc767b58ddc66ad94.tar.xz |
staging: comedi: drivers should not clear the async->events
The comedi core resets the async->events in comedi_buf_reset() which is
called when the subdevice is restored to an idle state and at the start
of an async command. The async->events are also cleared after handling
the events in comedi_event().
Drivers should not clear the events manually.
Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/comedi/drivers/addi-data/hwdrv_apci3120.c | 2 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/addi-data/hwdrv_apci3200.c | 1 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/adl_pci9118.c | 2 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/comedi_test.c | 1 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/das16m1.c | 1 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/das1800.c | 1 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/das800.c | 1 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/gsc_hpdi.c | 2 | ||||
-rw-r--r-- | drivers/staging/comedi/drivers/me4000.c | 3 |
9 files changed, 0 insertions, 14 deletions
diff --git a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci3120.c b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci3120.c index bd05857..978cc57 100644 --- a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci3120.c +++ b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci3120.c @@ -1574,8 +1574,6 @@ static int i_APCI3120_InterruptHandleEos(struct comedi_device *dev) n_chan = devpriv->ui_AiNbrofChannels; - s->async->events = 0; - for (i = 0; i < n_chan; i++) err &= comedi_buf_put(s->async, inw(dev->iobase + 0)); diff --git a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci3200.c b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci3200.c index 8c85a09..89ffc1f 100644 --- a/drivers/staging/comedi/drivers/addi-data/hwdrv_apci3200.c +++ b/drivers/staging/comedi/drivers/addi-data/hwdrv_apci3200.c @@ -2619,7 +2619,6 @@ static int i_APCI3200_InterruptHandleEos(struct comedi_device *dev) /* BEGIN JK 18.10.2004: APCI-3200 Driver update 0.7.57 -> 0.7.68 */ /* This value is not used */ /* ui_ChannelNumber = inl(devpriv->iobase+s_BoardInfos [dev->minor].i_Offset + 24); */ - s->async->events = 0; /* END JK 18.10.2004: APCI-3200 Driver update 0.7.57 -> 0.7.68 */ /*************************************/ diff --git a/drivers/staging/comedi/drivers/adl_pci9118.c b/drivers/staging/comedi/drivers/adl_pci9118.c index 980ce49..3cfa175 100644 --- a/drivers/staging/comedi/drivers/adl_pci9118.c +++ b/drivers/staging/comedi/drivers/adl_pci9118.c @@ -955,8 +955,6 @@ static void interrupt_pci9118_ai_onesample(struct comedi_device *dev, struct pci9118_private *devpriv = dev->private; unsigned short sampl; - s->async->events = 0; - if (int_adstat & devpriv->ai_maskerr) if (pci9118_decode_error_status(dev, s, int_adstat)) return; diff --git a/drivers/staging/comedi/drivers/comedi_test.c b/drivers/staging/comedi/drivers/comedi_test.c index 3f59666..cd95625 100644 --- a/drivers/staging/comedi/drivers/comedi_test.c +++ b/drivers/staging/comedi/drivers/comedi_test.c @@ -185,7 +185,6 @@ static void waveform_ai_interrupt(unsigned long arg) (devpriv->usec_remainder + elapsed_time) / devpriv->scan_period; devpriv->usec_remainder = (devpriv->usec_remainder + elapsed_time) % devpriv->scan_period; - async->events = 0; if (cmd->stop_src == TRIG_COUNT) { unsigned int remaining = cmd->stop_arg - devpriv->ai_count; diff --git a/drivers/staging/comedi/drivers/das16m1.c b/drivers/staging/comedi/drivers/das16m1.c index 70aecbc..7792258 100644 --- a/drivers/staging/comedi/drivers/das16m1.c +++ b/drivers/staging/comedi/drivers/das16m1.c @@ -416,7 +416,6 @@ static void das16m1_handler(struct comedi_device *dev, unsigned int status) s = dev->read_subdev; async = s->async; - async->events = 0; cmd = &async->cmd; /* figure out how many samples are in fifo */ diff --git a/drivers/staging/comedi/drivers/das1800.c b/drivers/staging/comedi/drivers/das1800.c index 9f353cf..8e975d6 100644 --- a/drivers/staging/comedi/drivers/das1800.c +++ b/drivers/staging/comedi/drivers/das1800.c @@ -646,7 +646,6 @@ static void das1800_ai_handler(struct comedi_device *dev) struct comedi_cmd *cmd = &async->cmd; unsigned int status = inb(dev->iobase + DAS1800_STATUS); - async->events = 0; /* select adc for base address + 0 */ outb(ADC, dev->iobase + DAS1800_SELECT); /* dma buffer full */ diff --git a/drivers/staging/comedi/drivers/das800.c b/drivers/staging/comedi/drivers/das800.c index a4fb3d6..3e40837 100644 --- a/drivers/staging/comedi/drivers/das800.c +++ b/drivers/staging/comedi/drivers/das800.c @@ -448,7 +448,6 @@ static int das800_ai_do_cmd(struct comedi_device *dev, das800_ind_write(dev, conv_bits, CONV_CONTROL); spin_unlock_irqrestore(&dev->spinlock, irq_flags); - async->events = 0; das800_enable(dev); return 0; } diff --git a/drivers/staging/comedi/drivers/gsc_hpdi.c b/drivers/staging/comedi/drivers/gsc_hpdi.c index de60a28..5af0f78 100644 --- a/drivers/staging/comedi/drivers/gsc_hpdi.c +++ b/drivers/staging/comedi/drivers/gsc_hpdi.c @@ -746,8 +746,6 @@ static irqreturn_t handle_interrupt(int irq, void *d) hpdi_intr_status = readl(devpriv->hpdi_iobase + INTERRUPT_STATUS_REG); hpdi_board_status = readl(devpriv->hpdi_iobase + BOARD_STATUS_REG); - async->events = 0; - if (hpdi_intr_status) { writel(hpdi_intr_status, devpriv->hpdi_iobase + INTERRUPT_STATUS_REG); diff --git a/drivers/staging/comedi/drivers/me4000.c b/drivers/staging/comedi/drivers/me4000.c index e739bcd..f02b31b 100644 --- a/drivers/staging/comedi/drivers/me4000.c +++ b/drivers/staging/comedi/drivers/me4000.c @@ -1112,9 +1112,6 @@ static irqreturn_t me4000_ai_isr(int irq, void *dev_id) if (!dev->attached) return IRQ_NONE; - /* Reset all events */ - s->async->events = 0; - if (inl(dev->iobase + ME4000_IRQ_STATUS_REG) & ME4000_IRQ_STATUS_BIT_AI_HF) { /* Read status register to find out what happened */ |