Commit 0a39ac29 authored by Bárbara Fernandes's avatar Bárbara Fernandes Committed by Jonathan Cameron

iio:adc:ad7923: Rewrite comparison to NULL

Solves checkpath.pl's message:

CHECK: Comparison to NULL could be written "!indio_dev"
Signed-off-by: default avatarBárbara Fernandes <barbara.fernandes@usp.br>
Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent 385c301c
......@@ -272,7 +272,7 @@ static int ad7923_probe(struct spi_device *spi)
int ret;
indio_dev = devm_iio_device_alloc(&spi->dev, sizeof(*st));
if (indio_dev == NULL)
if (!indio_dev)
return -ENOMEM;
st = iio_priv(indio_dev);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment