From: Jingoo Han <jg1.han@samsung.com>
To: linux-fbdev@vger.kernel.org
Subject: Re: [patch 2/2] backlight: lm3630: potential NULL deref in probe()
Date: Wed, 25 Sep 2013 09:13:28 +0000 [thread overview]
Message-ID: <002101ceb9cf$7f773250$7e6596f0$%han@samsung.com> (raw)
In-Reply-To: <20130925085549.GB6661@elgon.mountain>
On Wednesday, September 25, 2013 5:55 PM, Dan Carpenter wrote:
>
> "rval" needs to be signed for the error handling to work.
>
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
CC'ed Andrew Morton, Daniel Jeong,
Oh, you're right.
"rval" is used as below.
rval = lm3630a_read(pchip, REG_INT_STATUS);
Also, lm3630a_read() returns signed value; thus,
"rval" should be signed.
Thank you for sending the patch. :-)
Acked-by: Jingoo Han <jg1.han@samsung.com>
>
> diff --git a/drivers/video/backlight/lm3630a_bl.c b/drivers/video/backlight/lm3630a_bl.c
> index c63f918..65392f9 100644
> --- a/drivers/video/backlight/lm3630a_bl.c
> +++ b/drivers/video/backlight/lm3630a_bl.c
> @@ -105,7 +105,7 @@ static int lm3630a_chip_init(struct lm3630a_chip *pchip)
> /* interrupt handling */
> static void lm3630a_delayed_func(struct work_struct *work)
> {
> - unsigned int rval;
> + int rval;
> struct lm3630a_chip *pchip;
>
> pchip = container_of(work, struct lm3630a_chip, work.work);
next prev parent reply other threads:[~2013-09-25 9:13 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-25 8:55 [patch 2/2] backlight: lm3630: potential NULL deref in probe() Dan Carpenter
2013-09-25 9:13 ` Jingoo Han [this message]
2013-09-25 9:28 ` Jingoo Han
2013-09-25 9:34 ` Dan Carpenter
2013-09-25 9:36 ` Dan Carpenter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='002101ceb9cf$7f773250$7e6596f0$%han@samsung.com' \
--to=jg1.han@samsung.com \
--cc=linux-fbdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox