All of lore.kernel.org
 help / color / mirror / Atom feed
From: Julia Lawall <julia.lawall@inria.fr>
To: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Cc: "Mauro Carvalho Chehab" <mchehab@kernel.org>,
	linux-media@vger.kernel.org,
	"Kévin L'hôpital" <kevin.lhopital@bootlin.com>,
	"Sakari Ailus" <sakari.ailus@linux.intel.com>,
	linux-kernel@vger.kernel.org,
	"Linux Memory Management List" <linux-mm@kvack.org>,
	kbuild-all@lists.01.org
Subject: [PATCH] media: i2c: fix odd_ptr_err.cocci warnings
Date: Sat, 16 Jan 2021 21:11:13 +0100 (CET)	[thread overview]
Message-ID: <alpine.DEB.2.22.394.2101162109350.2697@hadrien> (raw)

From: kernel test robot <lkp@intel.com>

PTR_ERR should access the value just tested by IS_ERR

Generated by: scripts/coccinelle/tests/odd_ptr_err.cocci

Fixes: 11c0d8fdccc5 ("media: i2c: Add support for the OV8865 image sensor")
CC: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: kernel test robot <lkp@intel.com>
Signed-off-by: Julia Lawall <julia.lawall@inria.fr>
---

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   b3a3cbdec55b090d22a09f75efb7c7d34cb97f25
commit: 11c0d8fdccc56fa15cb15906480b4737c31dd085 [2650/3956] media: i2c: Add support for the OV8865 image sensor
:::::: branch date: 2 days ago
:::::: commit date: 4 days ago

 ov8865.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/media/i2c/ov8865.c
+++ b/drivers/media/i2c/ov8865.c
@@ -2849,7 +2849,7 @@ static int ov8865_probe(struct i2c_clien
 	sensor->avdd = devm_regulator_get(dev, "avdd");
 	if (IS_ERR(sensor->avdd)) {
 		dev_err(dev, "cannot get AVDD (analog) regulator\n");
-		ret = PTR_ERR(sensor->dvdd);
+		ret = PTR_ERR(sensor->avdd);
 		goto error_endpoint;
 	}


WARNING: multiple messages have this Message-ID (diff)
From: Julia Lawall <julia.lawall@inria.fr>
To: kbuild-all@lists.01.org
Subject: [PATCH] media: i2c: fix odd_ptr_err.cocci warnings
Date: Sat, 16 Jan 2021 21:11:13 +0100	[thread overview]
Message-ID: <alpine.DEB.2.22.394.2101162109350.2697@hadrien> (raw)

[-- Attachment #1: Type: text/plain, Size: 1203 bytes --]

From: kernel test robot <lkp@intel.com>

PTR_ERR should access the value just tested by IS_ERR

Generated by: scripts/coccinelle/tests/odd_ptr_err.cocci

Fixes: 11c0d8fdccc5 ("media: i2c: Add support for the OV8865 image sensor")
CC: Paul Kocialkowski <paul.kocialkowski@bootlin.com>
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: kernel test robot <lkp@intel.com>
Signed-off-by: Julia Lawall <julia.lawall@inria.fr>
---

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   b3a3cbdec55b090d22a09f75efb7c7d34cb97f25
commit: 11c0d8fdccc56fa15cb15906480b4737c31dd085 [2650/3956] media: i2c: Add support for the OV8865 image sensor
:::::: branch date: 2 days ago
:::::: commit date: 4 days ago

 ov8865.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/media/i2c/ov8865.c
+++ b/drivers/media/i2c/ov8865.c
@@ -2849,7 +2849,7 @@ static int ov8865_probe(struct i2c_clien
 	sensor->avdd = devm_regulator_get(dev, "avdd");
 	if (IS_ERR(sensor->avdd)) {
 		dev_err(dev, "cannot get AVDD (analog) regulator\n");
-		ret = PTR_ERR(sensor->dvdd);
+		ret = PTR_ERR(sensor->avdd);
 		goto error_endpoint;
 	}

             reply	other threads:[~2021-01-16 20:12 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-01-16 20:11 Julia Lawall [this message]
2021-01-16 20:11 ` [PATCH] media: i2c: fix odd_ptr_err.cocci warnings Julia Lawall
2021-01-18 13:55 ` Paul Kocialkowski
2021-02-01 13:04   ` Sakari Ailus
2021-02-01 13:04     ` Sakari Ailus
  -- strict thread matches above, loose matches on Subject: below --
2021-01-16 19:58 [linux-next:master 2650/3956] drivers/media/i2c/ov8865.c:2850:5-11: inconsistent IS_ERR and PTR_ERR on line 2852 kernel test robot
2021-01-16 19:58 ` [PATCH] media: i2c: fix odd_ptr_err.cocci warnings kernel test robot

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=alpine.DEB.2.22.394.2101162109350.2697@hadrien \
    --to=julia.lawall@inria.fr \
    --cc=kbuild-all@lists.01.org \
    --cc=kevin.lhopital@bootlin.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=mchehab@kernel.org \
    --cc=paul.kocialkowski@bootlin.com \
    --cc=sakari.ailus@linux.intel.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.