summaryrefslogtreecommitdiff
path: root/drivers/iio/adc/ad7292.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/iio/adc/ad7292.c')
-rw-r--r--drivers/iio/adc/ad7292.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/iio/adc/ad7292.c b/drivers/iio/adc/ad7292.c
index 92c68d467c50..a2f9fda25ff3 100644
--- a/drivers/iio/adc/ad7292.c
+++ b/drivers/iio/adc/ad7292.c
@@ -287,10 +287,8 @@ static int ad7292_probe(struct spi_device *spi)
ret = devm_add_action_or_reset(&spi->dev,
ad7292_regulator_disable, st);
- if (ret) {
- regulator_disable(st->reg);
+ if (ret)
return ret;
- }
ret = regulator_get_voltage(st->reg);
if (ret < 0)