From: YueHaibing <yuehaibing@huawei.com>
To: Bjorn Helgaas <bhelgaas@google.com>,
Kees Cook <keescook@chromium.org>,
Markus Elfring <elfring@users.sourceforge.net>,
Frederick Lawler <fred@fredlawl.com>,
Andy Shevchenko <andy.shevchenko@gmail.com>,
"Lukas Wunner" <lukas@wunner.de>,
Tyrel Datwyler <tyreld@linux.vnet.ibm.com>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
Cc: YueHaibing <yuehaibing@huawei.com>, <linux-pci@vger.kernel.org>,
<kernel-janitors@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: [PATCH -next] PCI: hotplug: Remove set but not used variable 'physical_slot'
Date: Wed, 26 Sep 2018 11:06:02 +0000 [thread overview]
Message-ID: <1537959962-83251-1-git-send-email-yuehaibing@huawei.com> (raw)
Fixes gcc '-Wunused-but-set-variable' warning:
drivers/pci/hotplug/cpqphp_core.c: In function 'init_SERR':
drivers/pci/hotplug/cpqphp_core.c:124:5: warning:
variable 'physical_slot' set but not used [-Wunused-but-set-variable]
Signed-off-by: YueHaibing <yuehaibing@huawei.com>
---
drivers/pci/hotplug/cpqphp_core.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/drivers/pci/hotplug/cpqphp_core.c b/drivers/pci/hotplug/cpqphp_core.c
index 95b7d60..16bbb18 100644
--- a/drivers/pci/hotplug/cpqphp_core.c
+++ b/drivers/pci/hotplug/cpqphp_core.c
@@ -121,7 +121,6 @@ static int init_SERR(struct controller *ctrl)
{
u32 tempdword;
u32 number_of_slots;
- u8 physical_slot;
if (!ctrl)
return 1;
@@ -131,7 +130,6 @@ static int init_SERR(struct controller *ctrl)
number_of_slots = readb(ctrl->hpc_reg + SLOT_MASK) & 0x0F;
/* Loop through slots */
while (number_of_slots) {
- physical_slot = tempdword;
writeb(0, ctrl->hpc_reg + SLOT_SERR);
tempdword++;
number_of_slots--;
next reply other threads:[~2018-09-26 10:57 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-26 11:06 YueHaibing [this message]
2018-09-26 19:24 ` [PATCH -next] PCI: hotplug: Remove set but not used variable 'physical_slot' Bjorn Helgaas
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=1537959962-83251-1-git-send-email-yuehaibing@huawei.com \
--to=yuehaibing@huawei.com \
--cc=andy.shevchenko@gmail.com \
--cc=bhelgaas@google.com \
--cc=elfring@users.sourceforge.net \
--cc=fred@fredlawl.com \
--cc=keescook@chromium.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=lukas@wunner.de \
--cc=rafael.j.wysocki@intel.com \
--cc=tyreld@linux.vnet.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).