All of lore.kernel.org
 help / color / mirror / Atom feed
From: Liam Girdwood <lrg@slimlogic.co.uk>
To: Roel Kluin <roel.kluin@gmail.com>
Cc: Mark Brown <broonie@opensource.wolfsonmicro.com>,
	Andrew Morton <akpm@linux-foundation.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] regulator: wm831x_reg_read() failure unnoticed in wm831x_aldo_get_mode()
Date: Wed, 16 Dec 2009 15:57:11 +0000	[thread overview]
Message-ID: <1260979031.3525.307.camel@odin> (raw)
In-Reply-To: <4B27DE73.6060909@gmail.com>

On Tue, 2009-12-15 at 20:07 +0100, Roel Kluin wrote:
> ret should be signed to notice a failure in wm831x_reg_read().
> 
> Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
> ---
> Found using coccinelle: http://coccinelle.lip6.fr/
> 
> diff --git a/drivers/regulator/wm831x-ldo.c b/drivers/regulator/wm831x-ldo.c
> index 902db56..61e02ac 100644
> --- a/drivers/regulator/wm831x-ldo.c
> +++ b/drivers/regulator/wm831x-ldo.c
> @@ -470,7 +470,7 @@ static unsigned int wm831x_aldo_get_mode(struct regulator_dev *rdev)
>  	struct wm831x_ldo *ldo = rdev_get_drvdata(rdev);
>  	struct wm831x *wm831x = ldo->wm831x;
>  	int on_reg = ldo->base + WM831X_LDO_ON_CONTROL;
> -	unsigned int ret;
> +	int ret;
>  
>  	ret = wm831x_reg_read(wm831x, on_reg);
>  	if (ret < 0)

Applied.

Thanks

Liam


      parent reply	other threads:[~2009-12-16 15:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-15 19:07 [PATCH] regulator: wm831x_reg_read() failure unnoticed in wm831x_aldo_get_mode() Roel Kluin
2009-12-15 19:10 ` Mark Brown
2009-12-16 15:57 ` Liam Girdwood [this message]

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=1260979031.3525.307.camel@odin \
    --to=lrg@slimlogic.co.uk \
    --cc=akpm@linux-foundation.org \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=roel.kluin@gmail.com \
    /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 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.