iio: health: afe4403: Use devm IIO helpers
authorAndrew Davis <afd@ti.com>
Tue, 23 Jan 2024 14:09:16 +0000 (08:09 -0600)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sat, 17 Feb 2024 16:16:09 +0000 (16:16 +0000)
commite73a640fe3149cfa4677cefa34247350e322b563
tree1b0fb2d1ba4b68c9bcdd9b5687fcc07fa1cd93e2
parenteeb4c24a5c909be376675963767fbcd36072fc6a
iio: health: afe4403: Use devm IIO helpers

Use a device lifecycle managed IIO helper functions. This helps prevent
mistakes like unregistering and freeing out of order in cleanup functions
and forgetting to unregister and free on error paths.

Signed-off-by: Andrew Davis <afd@ti.com>
Link: https://lore.kernel.org/r/20240123140918.215818-2-afd@ti.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/health/afe4403.c