aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYueHaibing <yuehaibing@huawei.com>2018-09-26 07:06:02 -0400
committerBjorn Helgaas <bhelgaas@google.com>2018-10-02 17:04:40 -0400
commit37f1c5868e457386950e7e27212bfdcd9f77f302 (patch)
tree51a1766e75497e51aab7b62533b99bc4df4e0ef2
parent479e01a402f006746324a04a72bd949ceca5e73d (diff)
PCI: cpqphp: Remove set but not used variable 'physical_slot'
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> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
-rw-r--r--drivers/pci/hotplug/cpqphp_core.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/pci/hotplug/cpqphp_core.c b/drivers/pci/hotplug/cpqphp_core.c
index 95b7d60cf119..16bbb183695a 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)
121{ 121{
122 u32 tempdword; 122 u32 tempdword;
123 u32 number_of_slots; 123 u32 number_of_slots;
124 u8 physical_slot;
125 124
126 if (!ctrl) 125 if (!ctrl)
127 return 1; 126 return 1;
@@ -131,7 +130,6 @@ static int init_SERR(struct controller *ctrl)
131 number_of_slots = readb(ctrl->hpc_reg + SLOT_MASK) & 0x0F; 130 number_of_slots = readb(ctrl->hpc_reg + SLOT_MASK) & 0x0F;
132 /* Loop through slots */ 131 /* Loop through slots */
133 while (number_of_slots) { 132 while (number_of_slots) {
134 physical_slot = tempdword;
135 writeb(0, ctrl->hpc_reg + SLOT_SERR); 133 writeb(0, ctrl->hpc_reg + SLOT_SERR);
136 tempdword++; 134 tempdword++;
137 number_of_slots--; 135 number_of_slots--;