Re: [PATCH v5 5/7] iio: light: vcnl4000: Use IIO cleanup helpers

Kurt Borja
2026-01-22T22:22:33Z

On Thu Jan 22, 2026 at 2:12 PM -05, Jonathan Cameron wrote:
> On Tue, 20 Jan 2026 01:20:45 -0500
> Kurt Borja <kuurtb@gmail.com> wrote:
>
>> Use IIO_DEV_ACQUIRE_DIRECT_MODE() helper to automatically release direct
>> mode.
>>
>> Reviewed-by: David Lechner <dlechner@baylibre.com>
>> Reviewed-by: Nuno Sá <nuno.sa@analog.com>
>> Signed-off-by: Kurt Borja <kuurtb@gmail.com>
> Given sparse doesn't play well with this stuff, this is (I think) more or less expected.
> drivers/iio/light/vcnl4000.c: note: in included file (through include/linux/iio/buffer.h):
> ./include/linux/iio/iio.h:687:20: warning: context imbalance in 'vcnl4010_read_raw' - different lock contexts for basic block
> ./include/linux/iio/iio.h:687:20: warning: context imbalance in 'vcnl4010_write_raw' - different lock contexts for basic block
> ./include/linux/iio/iio.h:687:20: warning: context imbalance in 'vcnl4010_config_threshold' - different lock contexts for basic block
>
> Hopefully it will one day catch up or we'll move to an alternative for lock checking.

Yep, sadly it's to be expected when using cleanup.h stuff.

>
> J

--
Thanks,
~ Kurt