public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] backlight: Return proper error in l4f00242t03_probe if regulator_get fails
@ 2012-01-13  9:00 Axel Lin
  2012-01-13 10:00 ` Alberto Panizzo
  0 siblings, 1 reply; 2+ messages in thread
From: Axel Lin @ 2012-01-13  9:00 UTC (permalink / raw)
  To: linux-kernel; +Cc: Alberto Panizzo, Richard Purdie, Andrew Morton

Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
 drivers/video/backlight/l4f00242t03.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/video/backlight/l4f00242t03.c b/drivers/video/backlight/l4f00242t03.c
index fae421a..6022b67 100644
--- a/drivers/video/backlight/l4f00242t03.c
+++ b/drivers/video/backlight/l4f00242t03.c
@@ -190,6 +190,7 @@ static int __devinit l4f00242t03_probe(struct spi_device *spi)
 
 	priv->io_reg = regulator_get(&spi->dev, "vdd");
 	if (IS_ERR(priv->io_reg)) {
+		ret = PTR_ERR(priv->io_reg);
 		dev_err(&spi->dev, "%s: Unable to get the IO regulator\n",
 		       __func__);
 		goto err3;
@@ -197,6 +198,7 @@ static int __devinit l4f00242t03_probe(struct spi_device *spi)
 
 	priv->core_reg = regulator_get(&spi->dev, "vcore");
 	if (IS_ERR(priv->core_reg)) {
+		ret = PTR_ERR(priv->core_reg);
 		dev_err(&spi->dev, "%s: Unable to get the core regulator\n",
 		       __func__);
 		goto err4;
-- 
1.7.5.4




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

end of thread, other threads:[~2012-01-13 10:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-01-13  9:00 [PATCH] backlight: Return proper error in l4f00242t03_probe if regulator_get fails Axel Lin
2012-01-13 10:00 ` Alberto Panizzo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox