[PATCH 00/25] staging: comedi: tidy up async command termination
H Hartley Sweeten
hsweeten at visionengravers.com
Thu Sep 11 23:07:22 UTC 2014
The comedi async commands should stop if an error/overflow happens or when
the end-of-acquisition for the command is detected. Some of the drivers
do this correctly but many don't.
The cfc_handle_events() function automatically detects the events that would
terminate a command. If the events are set it calls the subdevice (*cancel)
operation to stop the command.
Convert all the drivers that still use comedi_event() to use cfc_handle_events()
instead. This allows removing the unnecessary cancel in the driver, if present,
and ensures that all the drivers terminate the commands if necessary.
The only drivers that still use comedi_event() directly are the usbdux drivers.
These have a "cancel" in the urb completion routines that does not do what the
(*cancel) does. I'm waiting for a reply from the author to see if this can
be changed.
H Hartley Sweeten (25):
staging: comedi: hwdrv_apci3120: use cfc_handle_events()
staging: comedi: hwdrv_apci3120: do cfc_handle_events() at end of interrupt
staging: comedi: hwdrv_apci3200: use cfc_handle_events()
staging: comedi: addi_apci_1032: use cfc_handle_events()
staging: comedi: addi_apci_1564: use cfc_handle_events()
staging: comedi: addi_apci_2032: use cfc_handle_events()
staging: comedi: addi_apci_3xxx: use cfc_handle_events()
staging: comedi: amplc_dio200_common: use cfc_handle_events()
staging: comedi: amplc_pc2360_common: use cfc_handle_events()
staging: comedi: comedi_parport: use cfc_handle_events()
staging: comedi: comedi_test: use cfc_handle_events()
staging: comedi: dmm32at: use cfc_handle_events()
staging: comedi: dt2814: use cfc_handle_events()
staging: comedi: me4000: use cfc_handle_events()
staging: comedi: ni_6527: use cfc_handle_events()
staging: comedi: ni_65xx: use cfc_handle_events()
staging: comedi: ni_atmio16d: use cfc_handle_events()
staging: comedi: pcl711: use cfc_handle_events()
staging: comedi: pcl726: use cfc_handle_events()
staging: comedi: pcmmio: use cfc_handle_events()
staging: comedi: pcmuio: use cfc_handle_events()
staging: comedi: s626: use cfc_handle_events()
staging: comedi: rtd520: clear FIFO when canceling async command
staging: comedi: rtd520: use cfc_handle_events()
staging: comedi: amplc_pci230: use cfc_handle_events()
.../comedi/drivers/addi-data/hwdrv_apci3120.c | 15 +-----
.../comedi/drivers/addi-data/hwdrv_apci3200.c | 3 +-
drivers/staging/comedi/drivers/addi_apci_1032.c | 2 +-
drivers/staging/comedi/drivers/addi_apci_1564.c | 2 +-
drivers/staging/comedi/drivers/addi_apci_2032.c | 8 +---
drivers/staging/comedi/drivers/addi_apci_3xxx.c | 2 +-
.../staging/comedi/drivers/amplc_dio200_common.c | 10 +---
.../staging/comedi/drivers/amplc_pc236_common.c | 2 +-
drivers/staging/comedi/drivers/amplc_pci230.c | 48 +++++++------------
drivers/staging/comedi/drivers/comedi_parport.c | 2 +-
drivers/staging/comedi/drivers/comedi_test.c | 7 +--
drivers/staging/comedi/drivers/dmm32at.c | 3 +-
drivers/staging/comedi/drivers/dt2814.c | 2 +-
drivers/staging/comedi/drivers/me4000.c | 3 +-
drivers/staging/comedi/drivers/ni_6527.c | 2 +-
drivers/staging/comedi/drivers/ni_65xx.c | 2 +-
drivers/staging/comedi/drivers/ni_atmio16d.c | 2 +-
drivers/staging/comedi/drivers/pcl711.c | 6 +--
drivers/staging/comedi/drivers/pcl726.c | 2 +-
drivers/staging/comedi/drivers/pcmmio.c | 16 ++-----
drivers/staging/comedi/drivers/pcmuio.c | 16 ++-----
drivers/staging/comedi/drivers/rtd520.c | 56 +++-------------------
drivers/staging/comedi/drivers/s626.c | 14 +-----
23 files changed, 57 insertions(+), 168 deletions(-)
--
2.0.3
More information about the devel
mailing list