mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Julia Lawall <julia.lawall@lip6.fr>, Tomas Novotny <tomas@novotny.cz>
Cc: Hartmut Knaack <knaack.h@gmx.de>,
	Lars-Peter Clausen <lars@metafoo.de>,
	Peter Meerwald-Stadler <pmeerw@pmeerw.net>,
	Yong Li <sdliyong@gmail.com>,
	Akinobu Mita <akinobu.mita@gmail.com>,
	linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org,
	kbuild-all@01.org
Subject: Re: [PATCH] iio: dac: mcp4725: fix odd_ptr_err.cocci warnings
Date: Sun, 23 Oct 2016 10:09:14 +0100	[thread overview]
Message-ID: <10011ef1-273a-80f9-b559-683ac6f68ac6@kernel.org> (raw)
In-Reply-To: <alpine.DEB.2.20.1610222238240.2191@hadrien>

On 22/10/16 21:41, Julia Lawall wrote:
> PTR_ERR should access the value just tested by IS_ERR
> 
> Generated by: scripts/coccinelle/tests/odd_ptr_err.cocci
> 
> CC: Tomas Novotny <tomas@novotny.cz>
> Signed-off-by: Julia Lawall <julia.lawall@lip6.fr>
> Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
Looks fairly obvious to me and I want to get a pull request out
shortly so applied.

Thanks,

Jonathan
> ---
> 
> Please take the patch only if it's a positive warning. Thanks!
> 
> Not checked at all.  This is being reported on the following tree:
> 
> tree:   https://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio.git
> testing
> head:   2796a310d462f73954c0ce8ffabaf4baacaecca1
> commit: e0b80def1faa901d83a7d580e8aa4ad4a512bedf [109/113] iio: dac:
> mcp4725: support voltage reference selection
> :::::: branch date: 2 hours ago
> :::::: commit date: 2 hours ago
> 
> 
>  mcp4725.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> --- a/drivers/iio/dac/mcp4725.c
> +++ b/drivers/iio/dac/mcp4725.c
> @@ -418,7 +418,7 @@ static int mcp4725_probe(struct i2c_clie
>  	if (pdata->use_vref) {
>  		data->vref_reg = devm_regulator_get(&client->dev, "vref");
>  		if (IS_ERR(data->vref_reg)) {
> -			err = PTR_ERR(data->vdd_reg);
> +			err = PTR_ERR(data->vref_reg);
>  			goto err_disable_vdd_reg;
>  		}
> 

      reply	other threads:[~2016-10-23  9:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-22 20:41 Julia Lawall
2016-10-23  9:09 ` Jonathan Cameron [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=10011ef1-273a-80f9-b559-683ac6f68ac6@kernel.org \
    --to=jic23@kernel.org \
    --cc=akinobu.mita@gmail.com \
    --cc=julia.lawall@lip6.fr \
    --cc=kbuild-all@01.org \
    --cc=knaack.h@gmx.de \
    --cc=lars@metafoo.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pmeerw@pmeerw.net \
    --cc=sdliyong@gmail.com \
    --cc=tomas@novotny.cz \
    /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

all inboxes | Powered by JetHome®