[Skiboot] [PATCH] fsp/fsp-chiptod: Fix uninitialized value

Kamalesh Babulal kamalesh at linux.vnet.ibm.com
Mon Jul 13 20:12:23 AEST 2015


Initialized variable rc to 0, to fix uninitialized value
issue.

Fixes Coverity defect#101857.

Signed-off-by: Kamalesh Babulal <kamalesh at linux.vnet.ibm.com>
Cc: Mahesh Salgaonkar <mahesh at linux.vnet.ibm.com>
---
 hw/fsp/fsp-chiptod.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hw/fsp/fsp-chiptod.c b/hw/fsp/fsp-chiptod.c
index 69c59c6..ce7e9ce 100644
--- a/hw/fsp/fsp-chiptod.c
+++ b/hw/fsp/fsp-chiptod.c
@@ -27,7 +27,7 @@ static bool fsp_chiptod_update_topology(uint32_t cmd_sub_mod,
 	struct fsp_msg *resp;
 	enum chiptod_topology topo;
 	bool action;
-	uint8_t rc;
+	uint8_t rc = 0;
 
 	switch (cmd_sub_mod) {
 	case FSP_CMD_TOPO_ENABLE_DISABLE:
-- 
2.1.2



More information about the Skiboot mailing list