All of
 help / color / mirror / Atom feed
From: kbuild test robot <>
To: Maarten ter Huurne <>
Cc:, Mark Brown <>,
	Paul Cercueil <>,
	Liam Girdwood <>,
Subject: [PATCH] regulator: act8865: fix ptr_ret.cocci warnings
Date: Wed, 24 Jul 2019 17:22:36 +0800	[thread overview]
Message-ID: <20190724092236.witxtfmubun25l2t@1905cc33b6dd> (raw)
In-Reply-To: <>

From: kbuild test robot <>

drivers/regulator/act8865-regulator.c:447:8-14: WARNING: PTR_ERR_OR_ZERO can be used

 Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR

Generated by: scripts/coccinelle/api/ptr_ret.cocci

Fixes: 2d09a79bf637 ("regulator: act8865: Add support for act8600 charger")
CC: Maarten ter Huurne <>
Signed-off-by: kbuild test robot <>

tree: master
head:   9e6dfe8045f85f9b5aade47e4192482927e2791a
commit: 2d09a79bf637f91d1bbfcfd4520e3639dd15897c [2115/2398] regulator: act8865: Add support for act8600 charger

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

--- a/drivers/regulator/act8865-regulator.c
+++ b/drivers/regulator/act8865-regulator.c
@@ -444,7 +444,7 @@ static int act8600_charger_probe(struct
 	charger = devm_power_supply_register(dev, &act8600_charger_desc, &cfg);
-	return IS_ERR(charger) ? PTR_ERR(charger) : 0;
+	return PTR_ERR_OR_ZERO(charger);
 static int act8865_pmic_probe(struct i2c_client *client,

       reply	other threads:[~2019-07-24  9:23 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <>
2019-07-24  9:22 ` kbuild test robot [this message]
2019-07-25 17:43   ` Applied "regulator: act8865: fix ptr_ret.cocci warnings" to the regulator tree Mark Brown

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190724092236.witxtfmubun25l2t@1905cc33b6dd \ \ \ \ \ \ \ \

* 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.