summaryrefslogtreecommitdiffstats
path: root/drivers/iio/magnetometer/st_magn.h
diff options
context:
space:
mode:
authorAlexandru Ardelean <aardelean@deviqon.com>2021-07-20 10:46:40 +0300
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2021-07-24 16:35:05 +0100
commita442673b40f22be1d7ce7bfb9626461638a638da (patch)
treee0968f177536528d4ae80b2fbefbec85cbbead7b /drivers/iio/magnetometer/st_magn.h
parent674db1e9217a8cebe4e348989f9e9ec428ff2859 (diff)
downloadlinux-a442673b40f22be1d7ce7bfb9626461638a638da.tar.bz2
iio: accel: st_accel: use devm_iio_triggered_buffer_setup() for buffer
The st_accel_allocate_ring() function calls iio_triggered_buffer_setup() to allocate a triggered buffer. But the same can be done with devm_iio_triggered_buffer_setup() and then the st_accel_common_remove() no longer needs to manually deallocate it. We know that the parent of the IIO device is used to manage other instances of the devm unwind, so it can be used in the st_accel_allocate_ring() as well. Signed-off-by: Alexandru Ardelean <aardelean@deviqon.com> Link: https://lore.kernel.org/r/20210720074642.223293-2-aardelean@deviqon.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/iio/magnetometer/st_magn.h')
0 files changed, 0 insertions, 0 deletions