iio: health: afe4404: Use devm action helper for regulator disable
authorAndrew Davis <afd@ti.com>
Tue, 23 Jan 2024 14:09:17 +0000 (08:09 -0600)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sat, 17 Feb 2024 16:16:10 +0000 (16:16 +0000)
commit5ff7ea503cd40776b741a33de762cc3f71c3fc1a
tree1ae0228bafb0b2921618aa60ce8e17036f5530f6
parente73a640fe3149cfa4677cefa34247350e322b563
iio: health: afe4404: Use devm action helper for regulator disable

Use a device lifecycle managed action for regulator disable function.
This helps prevent mistakes like unregistering out of order in cleanup
functions and forgetting to unregister on error paths.

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