[Skiboot] [PATCH] ibm-fsp/firenze: Fix unused overwritten value

Stewart Smith stewart at linux.vnet.ibm.com
Tue Jun 21 11:57:52 AEST 2016


Found with static analysis:

939        id = ((uint64_t)p[1] << 32) | p[2];
    value_overwrite: Overwriting previous write to id with value 0ULL.
940        id = 0;

Fixes: 6884fe63
Signed-off-by: Stewart Smith <stewart at linux.vnet.ibm.com>
---
 platforms/ibm-fsp/firenze-pci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/platforms/ibm-fsp/firenze-pci.c b/platforms/ibm-fsp/firenze-pci.c
index b13f1e52fc05..4a9aff300504 100644
--- a/platforms/ibm-fsp/firenze-pci.c
+++ b/platforms/ibm-fsp/firenze-pci.c
@@ -937,7 +937,7 @@ static void firenze_pci_slot_fixup(struct pci_slot *slot)
 
 	/* FIXME: support fixup with generic way */
 	id = ((uint64_t)p[1] << 32) | p[2];
-	id = 0;
+
 	if (id != LX_VPD_2S4U_BACKPLANE &&
 	    id != LX_VPD_1S4U_BACKPLANE)
 		return;
-- 
2.1.4



More information about the Skiboot mailing list