diff mbox

[1/8] p7ioc_err_inject_io32() - Fix uninitialized variable warning

Message ID 44d42c586eb571dc57a8393b39fcf8fe30df517c.1435048541.git.kamalesh@linux.vnet.ibm.com
State Accepted
Headers show

Commit Message

Kamalesh Babulal June 23, 2015, 8:37 a.m. UTC
Fix uninitialized variable warning in p7ioc_err_inject_io32().

Fixes Coverity defect #97880

Signed-off-by: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
Reviewed-by: Gavin Shan <gwshan@linux.vnet.ibm.com>
---
 hw/p7ioc-phb.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Stewart Smith June 24, 2015, 6:13 a.m. UTC | #1
Kamalesh Babulal <kamalesh@linux.vnet.ibm.com> writes:
> Fix uninitialized variable warning in p7ioc_err_inject_io32().
>
> Fixes Coverity defect #97880
>
> Signed-off-by: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
> Reviewed-by: Gavin Shan <gwshan@linux.vnet.ibm.com>

Thanks, merged!
diff mbox

Patch

diff --git a/hw/p7ioc-phb.c b/hw/p7ioc-phb.c
index 89592c4..d282363 100644
--- a/hw/p7ioc-phb.c
+++ b/hw/p7ioc-phb.c
@@ -1408,6 +1408,7 @@  static int64_t p7ioc_err_inject_io32(struct p7ioc_phb *p, uint32_t pe_no,
 	uint64_t ctrl = PHB_PAPR_ERR_INJ_CTL_OUTB;
 	int32_t index;
 
+	a = 0x0ull;
 	addr = 0x0ull;
 	prefer = 0x0ull;
 	for (index = 0; index < 128; index++) {