From: Chen Zhou <chenzhou10@huawei.com>
To: <paulus@samba.org>, <mpe@ellerman.id.au>, <tyreld@linux.ibm.com>,
<bhelgaas@google.com>
Cc: <linuxppc-dev@lists.ozlabs.org>, <linux-pci@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <chenzhou10@huawei.com>
Subject: [PATCH -next] PCI: rpaphp: remove set but not used variable 'value'
Date: Thu, 12 Mar 2020 22:04:12 +0800 [thread overview]
Message-ID: <20200312140412.32373-1-chenzhou10@huawei.com> (raw)
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/pci/hotplug/rpaphp_core.c: In function is_php_type:
drivers/pci/hotplug/rpaphp_core.c:291:16: warning:
variable value set but not used [-Wunused-but-set-variable]
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Chen Zhou <chenzhou10@huawei.com>
---
drivers/pci/hotplug/rpaphp_core.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/pci/hotplug/rpaphp_core.c b/drivers/pci/hotplug/rpaphp_core.c
index e408e40..5d871ef 100644
--- a/drivers/pci/hotplug/rpaphp_core.c
+++ b/drivers/pci/hotplug/rpaphp_core.c
@@ -288,11 +288,10 @@ EXPORT_SYMBOL_GPL(rpaphp_check_drc_props);
static int is_php_type(char *drc_type)
{
- unsigned long value;
char *endptr;
/* PCI Hotplug nodes have an integer for drc_type */
- value = simple_strtoul(drc_type, &endptr, 10);
+ simple_strtoul(drc_type, &endptr, 10);
if (endptr == drc_type)
return 0;
--
2.7.4
next reply other threads:[~2020-03-12 14:12 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-12 14:04 Chen Zhou [this message]
2020-03-12 14:38 ` [PATCH -next] PCI: rpaphp: remove set but not used variable 'value' Bjorn Helgaas
2020-03-12 14:41 ` Bjorn Helgaas
2020-03-12 21:36 ` Tyrel Datwyler
2020-03-13 10:43 ` Michael Ellerman
2020-03-26 12:06 ` Michael Ellerman
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=20200312140412.32373-1-chenzhou10@huawei.com \
--to=chenzhou10@huawei.com \
--cc=bhelgaas@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mpe@ellerman.id.au \
--cc=paulus@samba.org \
--cc=tyreld@linux.ibm.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 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).