From f1df8662859e7edee134d3d77f241a32c9cfb8ef Mon Sep 17 00:00:00 2001 From: Ian Abbott Date: Tue, 6 May 2014 13:12:08 +0100 Subject: staging: comedi: pass subdevice to comedi_buf_read_free() Change the parameters of `comedi_buf_read_free()` to pass a pointer to the comedi subdevice instead of a pointer to the "async" structure belonging to the subdevice. The main aim at the moment is to replace all the `struct comedi_async *` parameters with `struct comedi_subdevice *` parameters in the comedi driver API. Signed-off-by: Ian Abbott Reviewed-by: H Hartley Sweeten Signed-off-by: Greg Kroah-Hartman --- drivers/staging/comedi/comedi_fops.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/staging/comedi/comedi_fops.c') diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c index 5164374f5ab2..365e191228be 100644 --- a/drivers/staging/comedi/comedi_fops.c +++ b/drivers/staging/comedi/comedi_fops.c @@ -994,7 +994,7 @@ static int do_bufinfo_ioctl(struct comedi_device *dev, if (bi.bytes_read && (s->subdev_flags & SDF_CMD_READ)) { bi.bytes_read = comedi_buf_read_alloc(s, bi.bytes_read); - comedi_buf_read_free(async, bi.bytes_read); + comedi_buf_read_free(s, bi.bytes_read); if (comedi_is_subdevice_idle(s) && async->buf_write_count == async->buf_read_count) { @@ -2273,7 +2273,7 @@ static ssize_t comedi_read(struct file *file, char __user *buf, size_t nbytes, } comedi_buf_read_alloc(s, n); - comedi_buf_read_free(async, n); + comedi_buf_read_free(s, n); count += n; nbytes -= n; -- cgit v1.2.3-55-g7522