diff options
author | Lucas Stankus <lucas.p.stankus@gmail.com> | 2021-05-23 14:12:16 -0300 |
---|---|---|
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | 2021-06-03 18:24:14 +0100 |
commit | 7d3049fbf3c34a253d32ccf12d4da37233b1db2a (patch) | |
tree | 2b16d8fd29b8d0bad80afb69bec45af75a3624f1 /drivers/staging/iio | |
parent | 9410685cb1838fd5130a0b5fcf8f9fb30e9c9f11 (diff) |
staging: iio: cdc: ad7746: clean up probe return
Slight simplication of the probe return on device register.
Signed-off-by: Lucas Stankus <lucas.p.stankus@gmail.com>
Reviewed-by: Alexandru Ardelean <ardeleanalex@gmail.com>
Link: https://lore.kernel.org/r/45443b8306893576824effaff57d40231de8e813.1621786036.git.lucas.p.stankus@gmail.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Diffstat (limited to 'drivers/staging/iio')
-rw-r--r-- | drivers/staging/iio/cdc/ad7746.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/drivers/staging/iio/cdc/ad7746.c b/drivers/staging/iio/cdc/ad7746.c index 12b2554a85b5..367a5990ae35 100644 --- a/drivers/staging/iio/cdc/ad7746.c +++ b/drivers/staging/iio/cdc/ad7746.c @@ -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[] = { |