diff options
author | H Hartley Sweeten <hsweeten@visionengravers.com> | 2014-11-05 17:31:33 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-11-07 17:29:41 (GMT) |
commit | f615915ee5faf74d8912df1694e810c8269f6b3f (patch) | |
tree | 12db09c618ee6a64feddfc626b31552d1e988362 /drivers/staging/comedi/comedidev.h | |
parent | a65ccf634c91005bfc2c715b09aa43c1b18ce865 (diff) | |
download | linux-f615915ee5faf74d8912df1694e810c8269f6b3f.tar.xz |
staging: comedi: drivers: introduce comedi_nsamples_left()
Introduce a helper function to calculate the number of samples remaining
when the cmd->stop_src is TRIG_COUNT.
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/staging/comedi/comedidev.h')
-rw-r--r-- | drivers/staging/comedi/comedidev.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/staging/comedi/comedidev.h b/drivers/staging/comedi/comedidev.h index 616e9b0..77be191 100644 --- a/drivers/staging/comedi/comedidev.h +++ b/drivers/staging/comedi/comedidev.h @@ -518,6 +518,8 @@ unsigned int comedi_dio_update_state(struct comedi_subdevice *, unsigned int comedi_bytes_per_scan(struct comedi_subdevice *s); unsigned int comedi_nscans_left(struct comedi_subdevice *s, unsigned int nscans); +unsigned int comedi_nsamples_left(struct comedi_subdevice *s, + unsigned int nsamples); void comedi_inc_scan_progress(struct comedi_subdevice *s, unsigned int num_bytes); |