]> www.infradead.org Git - users/jedix/linux-maple.git/commit
iio: adc: ad_sigma_delta: Switch to sparse friendly iio_device_claim/release_direct()
authorJonathan Cameron <Jonathan.Cameron@huawei.com>
Mon, 17 Feb 2025 14:16:20 +0000 (14:16 +0000)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Tue, 4 Mar 2025 13:17:49 +0000 (13:17 +0000)
commit6eedf172d964be30364c3d8ac30751a6ce4815d8
tree21c136174fd98b05084876b4e509635900052614
parentbbd841f9d02c7a32243441e49496f0f915e536df
iio: adc: ad_sigma_delta: Switch to sparse friendly iio_device_claim/release_direct()

These new functions allow sparse to find failures to release
direct mode reducing chances of bugs over the claim_direct_mode()
functions that are deprecated.

This is a complex function with a lot more than the release of direct
mode to unwind on error. As such no attempt made to factor out
the inner code.

Cc: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
Reviewed-by: Nuno Sá <nuno.sa@analog.com>
Link: https://patch.msgid.link/20250217141630.897334-21-jic23@kernel.org
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/ad_sigma_delta.c