linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Zheng Yongjun <zhengyongjun3@huawei.com>
To: <leoyang.li@nxp.com>, <linuxppc-dev@lists.ozlabs.org>
Cc: Zheng Yongjun <zhengyongjun3@huawei.com>,
	network <network@ubuntu.network>
Subject: [PATCH] qbman: Remove set but not used variable 'err'
Date: Fri, 3 Apr 2020 15:35:27 +0800	[thread overview]
Message-ID: <1585899327-2690-1-git-send-email-zhengyongjun3@huawei.com> (raw)

From: network <network@ubuntu.network>

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/soc/fsl/qbman/bman.c:640:6: warning: variable ‘err’ set but not used [-Wunused-but-set-variable]
  int err = 0;
      ^~~
err is never used, so remove it.

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
Signed-off-by: network <network@ubuntu.network>
---
 drivers/soc/fsl/qbman/bman.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/soc/fsl/qbman/bman.c b/drivers/soc/fsl/qbman/bman.c
index f4fb527..0a24433 100644
--- a/drivers/soc/fsl/qbman/bman.c
+++ b/drivers/soc/fsl/qbman/bman.c
@@ -637,7 +637,6 @@ int bman_p_irqsource_add(struct bman_portal *p, u32 bits)
 
 int bm_shutdown_pool(u32 bpid)
 {
-	int err = 0;
 	struct bm_mc_command *bm_cmd;
 	union bm_mc_result *bm_res;
 
@@ -650,7 +649,6 @@ int bm_shutdown_pool(u32 bpid)
 		bm_mc_commit(&p->p, BM_MCC_VERB_CMD_ACQUIRE | 1);
 		if (!bm_mc_result_timeout(&p->p, &bm_res)) {
 			pr_crit("BMan Acquire Command timedout\n");
-			err = -ETIMEDOUT;
 			goto done;
 		}
 		if (!(bm_res->verb & BM_MCR_VERB_ACQUIRE_BUFCOUNT)) {
-- 
2.7.4


                 reply	other threads:[~2020-04-03 10:41 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1585899327-2690-1-git-send-email-zhengyongjun3@huawei.com \
    --to=zhengyongjun3@huawei.com \
    --cc=leoyang.li@nxp.com \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=network@ubuntu.network \
    /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;
as well as URLs for NNTP newsgroup(s).