Browse Source

[qib7322] Fix compiler warning on gcc 4.7

Originally-fixed-by: Christian Hesse <list@eworm.de>
Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 12 years ago
parent
commit
1ac62b914e
1 changed files with 3 additions and 0 deletions
  1. 3
    0
      src/drivers/infiniband/qib7322.c

+ 3
- 0
src/drivers/infiniband/qib7322.c View File

2062
 	struct QIB_7322_ahb_transaction_reg xact;
2062
 	struct QIB_7322_ahb_transaction_reg xact;
2063
 	int rc;
2063
 	int rc;
2064
 
2064
 
2065
+	/* Avoid returning uninitialised data on error */
2066
+	*data = 0;
2067
+
2065
 	/* Initiate transaction */
2068
 	/* Initiate transaction */
2066
 	memset ( &xact, 0, sizeof ( xact ) );
2069
 	memset ( &xact, 0, sizeof ( xact ) );
2067
 	BIT_FILL_2 ( &xact,
2070
 	BIT_FILL_2 ( &xact,

Loading…
Cancel
Save