2012-10-11 05:11:45

by Axel Lin

[permalink] [raw]
Subject: [PATCH] backlight: lm3639: Return proper error in lm3639_bled_mode_store error paths

Signed-off-by: Axel Lin <[email protected]>
---
drivers/video/backlight/lm3639_bl.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/video/backlight/lm3639_bl.c b/drivers/video/backlight/lm3639_bl.c
index c6915c6..585949b 100644
--- a/drivers/video/backlight/lm3639_bl.c
+++ b/drivers/video/backlight/lm3639_bl.c
@@ -206,11 +206,11 @@ static ssize_t lm3639_bled_mode_store(struct device *dev,

out:
dev_err(pchip->dev, "%s:i2c access fail to register\n", __func__);
- return size;
+ return ret;

out_input:
dev_err(pchip->dev, "%s:input conversion fail\n", __func__);
- return size;
+ return ret;

}

--
1.7.9.5



2012-10-12 04:49:14

by Daniel Jeong

[permalink] [raw]
Subject: Re: [PATCH] backlight: lm3639: Return proper error in lm3639_bled_mode_store error paths

2012년 10월 11일 14:11, Axel Lin 쓴 글:
> Signed-off-by: Axel Lin <[email protected]>
> ---
> drivers/video/backlight/lm3639_bl.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/video/backlight/lm3639_bl.c b/drivers/video/backlight/lm3639_bl.c
> index c6915c6..585949b 100644
> --- a/drivers/video/backlight/lm3639_bl.c
> +++ b/drivers/video/backlight/lm3639_bl.c
> @@ -206,11 +206,11 @@ static ssize_t lm3639_bled_mode_store(struct device *dev,
>
> out:
> dev_err(pchip->dev, "%s:i2c access fail to register\n", __func__);
> - return size;
> + return ret;
>
> out_input:
> dev_err(pchip->dev, "%s:input conversion fail\n", __func__);
> - return size;
> + return ret;
>
> }
>

Thank you Alex for fixing code.
Acked-by: G.Shark Jeong<[email protected]>