summaryrefslogtreecommitdiffstats
path: root/drivers/staging/comedi/comedi_fops.c
diff options
context:
space:
mode:
authorIan Abbott2014-05-06 14:12:05 +0200
committerGreg Kroah-Hartman2014-05-23 14:25:48 +0200
commit940dd35d5812ead0b93f3f2a1f44732ac069000b (patch)
treefd3aedc855a8dbc15cf1cf7f92e5c4819ffe6051 /drivers/staging/comedi/comedi_fops.c
parentstaging: comedi: pass subdevice to comedi_buf_write_alloc() (diff)
downloadkernel-qcow2-linux-940dd35d5812ead0b93f3f2a1f44732ac069000b.tar.gz
kernel-qcow2-linux-940dd35d5812ead0b93f3f2a1f44732ac069000b.tar.xz
kernel-qcow2-linux-940dd35d5812ead0b93f3f2a1f44732ac069000b.zip
staging: comedi: pass subdevice to comedi_buf_write_free()
Change the parameters of `comedi_buf_write_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 <abbotti@mev.co.uk> Reviewed-by: H Hartley Sweeten <hsweeten@visionengravers.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/comedi/comedi_fops.c')
-rw-r--r--drivers/staging/comedi/comedi_fops.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/staging/comedi/comedi_fops.c b/drivers/staging/comedi/comedi_fops.c
index 58c1f6e18d27..c7010b315701 100644
--- a/drivers/staging/comedi/comedi_fops.c
+++ b/drivers/staging/comedi/comedi_fops.c
@@ -1005,7 +1005,7 @@ static int do_bufinfo_ioctl(struct comedi_device *dev,
if (bi.bytes_written && (s->subdev_flags & SDF_CMD_WRITE)) {
bi.bytes_written =
comedi_buf_write_alloc(s, bi.bytes_written);
- comedi_buf_write_free(async, bi.bytes_written);
+ comedi_buf_write_free(s, bi.bytes_written);
}
copyback_position:
@@ -2167,7 +2167,7 @@ static ssize_t comedi_write(struct file *file, const char __user *buf,
n -= m;
retval = -EFAULT;
}
- comedi_buf_write_free(async, n);
+ comedi_buf_write_free(s, n);
count += n;
nbytes -= n;