All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: kbuild@lists.01.org
Subject: [PATCH] clk: imx: gate2: fix returnvar.cocci warnings
Date: Tue, 03 Nov 2020 23:52:53 +0800	[thread overview]
Message-ID: <20201103155253.GA29109@8dae5f89e272> (raw)
In-Reply-To: <202011032316.QbcWGpHd-lkp@intel.com>

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

CC: kbuild-all(a)lists.01.org
CC: Linux Memory Management List <linux-mm@kvack.org>
TO: Abel Vesa <abel.vesa@nxp.com>
CC: Shawn Guo <shawnguo@kernel.org>
CC: Sascha Hauer <s.hauer@pengutronix.de>
CC: Michael Turquette <mturquette@baylibre.com>
CC: Stephen Boyd <sboyd@kernel.org>
CC: Pengutronix Kernel Team <kernel@pengutronix.de>
CC: Fabio Estevam <festevam@gmail.com>
CC: NXP Linux Team <linux-imx@nxp.com>
CC: Anson Huang <Anson.Huang@nxp.com>
CC: "Jonathan Neuschäfer" <j.neuschaefer@gmx.net>

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

drivers/clk/imx/clk-gate2.c:45:5-8: Unneeded variable: "ret". Return "0" on line 60


 Remove unneeded variable used to store return value.

Generated by: scripts/coccinelle/misc/returnvar.cocci

Fixes: 12309428c277 ("clk: imx: gate2: Remove the IMX_CLK_GATE2_SINGLE_BIT special case")
CC: Abel Vesa <abel.vesa@nxp.com>
Signed-off-by: kernel test robot <lkp@intel.com>
---

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   c50585161e791d5ddb924da98741fdf413a0480a
commit: 12309428c27737c21735fb28540c6c6f69f632f6 [2873/3099] clk: imx: gate2: Remove the IMX_CLK_GATE2_SINGLE_BIT special case
:::::: branch date: 9 hours ago
:::::: commit date: 16 hours ago

Please take the patch only if it's a positive warning. Thanks!

 clk-gate2.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

--- a/drivers/clk/imx/clk-gate2.c
+++ b/drivers/clk/imx/clk-gate2.c
@@ -42,7 +42,6 @@ static int clk_gate2_enable(struct clk_h
 	struct clk_gate2 *gate = to_clk_gate2(hw);
 	u32 reg;
 	unsigned long flags;
-	int ret = 0;
 
 	spin_lock_irqsave(gate->lock, flags);
 
@@ -57,7 +56,7 @@ static int clk_gate2_enable(struct clk_h
 out:
 	spin_unlock_irqrestore(gate->lock, flags);
 
-	return ret;
+	return 0;
 }
 
 static void clk_gate2_disable(struct clk_hw *hw)

      reply	other threads:[~2020-11-03 15:52 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-03 15:52 [linux-next:master 2873/3099] drivers/clk/imx/clk-gate2.c:45:5-8: Unneeded variable: "ret". Return "0" on line 60 kernel test robot
2020-11-03 15:52 ` kernel test robot [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=20201103155253.GA29109@8dae5f89e272 \
    --to=lkp@intel.com \
    --cc=kbuild@lists.01.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 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.