Commit 7d3049fb authored by Lucas Stankus's avatar Lucas Stankus Committed by Jonathan Cameron

staging: iio: cdc: ad7746: clean up probe return

Slight simplication of the probe return on device register.
Signed-off-by: default avatarLucas Stankus <lucas.p.stankus@gmail.com>
Reviewed-by: default avatarAlexandru Ardelean <ardeleanalex@gmail.com>
Link: https://lore.kernel.org/r/45443b8306893576824effaff57d40231de8e813.1621786036.git.lucas.p.stankus@gmail.comSigned-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent 9410685c
......@@ -734,11 +734,7 @@ static int ad7746_probe(struct i2c_client *client,
if (ret < 0)
return ret;
ret = devm_iio_device_register(indio_dev->dev.parent, indio_dev);
if (ret)
return ret;
return 0;
return devm_iio_device_register(indio_dev->dev.parent, indio_dev);
}
static const struct i2c_device_id ad7746_id[] = {
......
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