]> www.infradead.org Git - users/jedix/linux-maple.git/commit
iio: imu: adis: add cleanup based lock helpers
authorNuno Sa <nuno.sa@analog.com>
Tue, 18 Jun 2024 13:32:06 +0000 (15:32 +0200)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Tue, 25 Jun 2024 20:04:49 +0000 (21:04 +0100)
commite6cab1ad9769a6b03dd1ba7ace106c36de85b1a8
treefef04b5fb317eb185556f3b0a2d944f242969a21
parentd305b7f34ee11c4901b8da150b641bcffbd3e951
iio: imu: adis: add cleanup based lock helpers

Add two new lock helpers that make use of the cleanup guard() and
scoped_guard() macros. Thus, users won't have to worry about unlocking
which is less prone to errors and allows for simpler error paths.

Signed-off-by: Nuno Sa <nuno.sa@analog.com>
Link: https://patch.msgid.link/20240618-dev-iio-adis-cleanup-v1-3-bd93ce7845c7@analog.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
include/linux/iio/imu/adis.h