]> git.ipfire.org Git - thirdparty/linux.git/commit
iio: adc: ti-ads7950: switch to using guard() notation
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Mon, 6 Apr 2026 04:39:23 +0000 (21:39 -0700)
committerJonathan Cameron <jic23@kernel.org>
Mon, 27 Apr 2026 08:58:17 +0000 (09:58 +0100)
commit3bfc60fc10121ea3640b11c5c11cb9be72817186
treea3ae27a17c42e6f3555c4fc0924a4a407e56bd06
parent7a89047a361c347cafe98f432d3df1686592ecce
iio: adc: ti-ads7950: switch to using guard() notation

guard() notation allows early returns when encountering errors, making
control flow more obvious. Use it.

Reviewed-by: David Lechner <dlechner@baylibre.com>
Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Tested-by: David Lechner <dlechner@baylibre.com>
Reviewed-by: Linus Walleij <linusw@kernel.org>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@intel.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/ti-ads7950.c