]> git.baikalelectronics.ru Git - kernel.git/commit
iio: adc: ad7476: implement devm_add_action_or_reset
authorBeniamin Bia <beniamin.bia@analog.com>
Wed, 11 Mar 2020 08:43:28 +0000 (10:43 +0200)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Sat, 21 Mar 2020 10:28:08 +0000 (10:28 +0000)
commite9c5ea4029fdd52251ef0b02ca8673b1059ecd4b
tree5d88e1cfb21eaff7d49847f54d2a6b2c6b2f58ad
parent2e38d658f47542ed5a98b66d903443b7819b1fee
iio: adc: ad7476: implement devm_add_action_or_reset

Use devm_add_action_or_reset to automatically disable the device
when it is removed or an error occurs during probe routine.

Signed-off-by: Beniamin Bia <beniamin.bia@analog.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/ad7476.c