]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commitdiff
staging: comedi: dt3000: use cfc_handle_events()
authorH Hartley Sweeten <hsweeten@visionengravers.com>
Sat, 8 Mar 2014 00:31:42 +0000 (17:31 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 17 Mar 2014 20:55:56 +0000 (13:55 -0700)
Use the comedi_fc helper function to automatically call the subdevice
(*cancel) function when needed and call comedi_event().

Update the Kconfig so that COMEDI_DT3000 selects COMEDI_FC.

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>
drivers/staging/comedi/Kconfig
drivers/staging/comedi/drivers/dt3000.c

index 2fb0cc042dd5192eb3049dbeba90c7903b02299c..279364a7dc9e5a83a49b697ca4b3884596ce0e49 100644 (file)
@@ -860,6 +860,7 @@ config COMEDI_DAS08_PCI
 
 config COMEDI_DT3000
        tristate "Data Translation DT3000 series support"
+       select COMEDI_FC
        ---help---
          Enable support for Data Translation DT3000 series
          DT3001, DT3001-PGL, DT3002, DT3003, DT3003-PGL, DT3004, DT3005 and
index f54685ed463c5316712cebbb7a55d9252d44c1e0..436e451cadf5e1a72d6994fbed30f93a1e6d8e16 100644 (file)
@@ -369,12 +369,10 @@ static irqreturn_t dt3k_interrupt(int irq, void *d)
                s->async->events |= COMEDI_CB_ERROR | COMEDI_CB_EOA;
 
        debug_n_ints++;
-       if (debug_n_ints >= 10) {
-               dt3k_ai_cancel(dev, s);
+       if (debug_n_ints >= 10)
                s->async->events |= COMEDI_CB_EOA;
-       }
 
-       comedi_event(dev, s);
+       cfc_handle_events(dev, s);
        return IRQ_HANDLED;
 }