All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] iio: ad5686: fix optional reference voltage declaration
@ 2015-02-02 16:12 Urs Fässler
  2015-02-02 17:47 ` Lars-Peter Clausen
  0 siblings, 1 reply; 3+ messages in thread
From: Urs Fässler @ 2015-02-02 16:12 UTC (permalink / raw)
  To: lars; +Cc: urs.fassler, Michael.Hennerich, linux-iio

[-- Attachment #1: Type: text/plain, Size: 758 bytes --]

When not using the "_optional" function, a dummy regulator is returned
and the driver fails to initialize.

Signed-off-by: Urs Fässler <urs.fassler@bytesatwork.ch>
---
 drivers/iio/dac/ad5686.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/iio/dac/ad5686.c b/drivers/iio/dac/ad5686.c
index f57562a..15c73e2 100644
--- a/drivers/iio/dac/ad5686.c
+++ b/drivers/iio/dac/ad5686.c
@@ -322,7 +322,7 @@ static int ad5686_probe(struct spi_device *spi)
 	st = iio_priv(indio_dev);
 	spi_set_drvdata(spi, indio_dev);
 -	st->reg = devm_regulator_get(&spi->dev, "vcc");
+	st->reg = devm_regulator_get_optional(&spi->dev, "vcc");
 	if (!IS_ERR(st->reg)) {
 		ret = regulator_enable(st->reg);
 		if (ret)
-- 
2.1.4



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] iio: ad5686: fix optional reference voltage declaration
  2015-02-02 16:12 [PATCH] iio: ad5686: fix optional reference voltage declaration Urs Fässler
@ 2015-02-02 17:47 ` Lars-Peter Clausen
  2015-02-04 16:56   ` Jonathan Cameron
  0 siblings, 1 reply; 3+ messages in thread
From: Lars-Peter Clausen @ 2015-02-02 17:47 UTC (permalink / raw)
  To: Urs Fässler; +Cc: Michael.Hennerich, linux-iio, Jonathan Cameron

On 02/02/2015 05:12 PM, Urs Fässler wrote:
> When not using the "_optional" function, a dummy regulator is returned
> and the driver fails to initialize.
>
> Signed-off-by: Urs Fässler <urs.fassler@bytesatwork.ch>

Acked-by: Lars-Peter Clausen <lars@metafoo.de>

Thanks.

Added Jonathan to Cc.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] iio: ad5686: fix optional reference voltage declaration
  2015-02-02 17:47 ` Lars-Peter Clausen
@ 2015-02-04 16:56   ` Jonathan Cameron
  0 siblings, 0 replies; 3+ messages in thread
From: Jonathan Cameron @ 2015-02-04 16:56 UTC (permalink / raw)
  To: Lars-Peter Clausen, Urs Fässler; +Cc: Michael.Hennerich, linux-iio

On 02/02/15 17:47, Lars-Peter Clausen wrote:
> On 02/02/2015 05:12 PM, Urs Fässler wrote:
>> When not using the "_optional" function, a dummy regulator is returned
>> and the driver fails to initialize.
>>
>> Signed-off-by: Urs Fässler <urs.fassler@bytesatwork.ch>
> 
> Acked-by: Lars-Peter Clausen <lars@metafoo.de>
> 
> Thanks.
> 
> Added Jonathan to Cc.
Applied to fixes-togreg (will hit git.kernel.org at the weekend
as I am travelling, and Greg / Mainline after the merge window)
Marked for stable.

Jonathan

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2015-02-04 18:40 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-02-02 16:12 [PATCH] iio: ad5686: fix optional reference voltage declaration Urs Fässler
2015-02-02 17:47 ` Lars-Peter Clausen
2015-02-04 16:56   ` Jonathan Cameron

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.