Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

iio: adc: ad9467: use the more common !val NULL check

Check !val instead of directing checking for NULL (val == NULL).
No functional changes intended.

Reviewed-by: David Lechner <dlechner@baylibre.com>
Signed-off-by: Nuno Sa <nuno.sa@analog.com>
Link: https://lore.kernel.org/r/20231207-iio-backend-prep-v2-7-a4a33bc4d70e@analog.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>

authored by

Nuno Sa and committed by
Jonathan Cameron
8bdfa4a2 6dd3fa9f

+1 -1
+1 -1
drivers/iio/adc/ad9467.c
··· 158 158 struct spi_device *spi = st->spi; 159 159 int ret; 160 160 161 - if (readval == NULL) { 161 + if (!readval) { 162 162 guard(mutex)(&st->lock); 163 163 ret = ad9467_spi_write(spi, reg, writeval); 164 164 if (ret)