Skip to content

Commit

Permalink
staging: iio: ad7606: set proper supply name to devm_regulator_get()
Browse files Browse the repository at this point in the history
The name passed to devm_regulator_get() should match the name of the
supply as specified in the device datasheet. The supply on this device
is called 'AVcc' while currently, the driver uses just 'vcc'.

Use 'avcc' to specify the supply voltage since it is custom to use the
lower-caps version of the datasheet name.

Suggested-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Eva Rachel Retuya <eraretuya@gmail.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
  • Loading branch information
Eva Rachel Retuya authored and Jonathan Cameron committed Oct 23, 2016
1 parent fa23105 commit 12edb97
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/staging/iio/adc/ad7606.c
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ int ad7606_probe(struct device *dev, int irq, void __iomem *base_address,
st->oversampling = 1;
INIT_WORK(&st->poll_work, &ad7606_poll_bh_to_ring);

st->reg = devm_regulator_get(dev, "vcc");
st->reg = devm_regulator_get(dev, "avcc");
if (!IS_ERR(st->reg)) {
ret = regulator_enable(st->reg);
if (ret)
Expand Down

0 comments on commit 12edb97

Please sign in to comment.