summaryrefslogtreecommitdiffstats
path: root/drivers/iio/buffer
diff options
context:
space:
mode:
authorAlexandru Ardelean <alexandru.ardelean@analog.com>2020-09-29 14:59:41 +0200
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2020-11-21 15:52:57 +0100
commit5e6dc43e2caa145627d2de2b5a7c65545f3fb639 (patch)
treea80e1f594bb52cb68510cc734d762f83d347d5e5 /drivers/iio/buffer
parentdt-bindings:iio:accel:domintech,dmard06: Move to trivial-devices.yaml (diff)
downloadlinux-5e6dc43e2caa145627d2de2b5a7c65545f3fb639.tar.xz
linux-5e6dc43e2caa145627d2de2b5a7c65545f3fb639.zip
iio: buffer: dmaengine: unwrap the use of iio_buffer_set_attrs()
The iio_buffer_set_attrs() helper will be removed in this series. So, just assign the attributes of the DMAEngine buffer logic directly. This is IIO buffer core context, so there is direct access to the buffer->attrs object. Signed-off-by: Alexandru Ardelean <alexandru.ardelean@analog.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Link: https://lore.kernel.org/r/20200929125949.69934-2-alexandru.ardelean@analog.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/buffer')
-rw-r--r--drivers/iio/buffer/industrialio-buffer-dmaengine.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/iio/buffer/industrialio-buffer-dmaengine.c b/drivers/iio/buffer/industrialio-buffer-dmaengine.c
index 93b4e9e6bb55..b0cb9a35f5cd 100644
--- a/drivers/iio/buffer/industrialio-buffer-dmaengine.c
+++ b/drivers/iio/buffer/industrialio-buffer-dmaengine.c
@@ -200,9 +200,8 @@ static struct iio_buffer *iio_dmaengine_buffer_alloc(struct device *dev,
iio_dma_buffer_init(&dmaengine_buffer->queue, chan->device->dev,
&iio_dmaengine_default_ops);
- iio_buffer_set_attrs(&dmaengine_buffer->queue.buffer,
- iio_dmaengine_buffer_attrs);
+ dmaengine_buffer->queue.buffer.attrs = iio_dmaengine_buffer_attrs;
dmaengine_buffer->queue.buffer.access = &iio_dmaengine_buffer_ops;
return &dmaengine_buffer->queue.buffer;