staging: comedi: ni_mio_common: use cfc_handle_events()
The ni_event() function in this file is an open coded version of cfc_handle_events() where instead of calling the subdevice (*cancel) function a switch is used to call the function based on the subdevice 'index'. Use the comedi_fc helper function to simplify the code. This also allows removing a couple of the forward declarations. Fix the #ifdef/#endif for the ni_gpct_cancel() foward declaration and around the function. This function is now only referenced by code that is blocked with #ifdef PCIDMA. This source file is included by the ni_atmio, ni_mio_cs, and ni_pcimio drivers. In the Kconfig, the config options for these drivers already select 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>
Showing
Please register or sign in to comment