diff --git a/lib/sw_services/xilskey/src/changelog.txt b/lib/sw_services/xilskey/src/changelog.txt index 3342cd72..0599624d 100755 --- a/lib/sw_services/xilskey/src/changelog.txt +++ b/lib/sw_services/xilskey/src/changelog.txt @@ -22,5 +22,6 @@ * 2.00 hk 02/12/14 Changed makefile to remove '-p' option with mkdir. * CR#773090 * 2.1 kvn 04/01/15 Fixed warnings. CR#716453. + * 2.1 sk 04/03/15 Initialized RSAKeyReadback with Zeros CR# 829723. * ********************************************************************************/ diff --git a/lib/sw_services/xilskey/src/include/xilskey_eps.h b/lib/sw_services/xilskey/src/include/xilskey_eps.h index 2266de26..35ac7c93 100755 --- a/lib/sw_services/xilskey/src/include/xilskey_eps.h +++ b/lib/sw_services/xilskey/src/include/xilskey_eps.h @@ -50,6 +50,7 @@ * Change in API: * u32 XilSKey_EfusePs_Read(XilSKey_EPs *PsInstancePtr) * 2.00 hk 23/01/14 Changed PS efuse error codes for voltage out of range +* 2.1 sk 04/03/15 Initialized RSAKeyReadback with Zeros CR# 829723. * * *****************************************************************************/ diff --git a/lib/sw_services/xilskey/src/xilskey_eps.c b/lib/sw_services/xilskey/src/xilskey_eps.c index fe0d0a87..b14f8378 100755 --- a/lib/sw_services/xilskey/src/xilskey_eps.c +++ b/lib/sw_services/xilskey/src/xilskey_eps.c @@ -44,6 +44,7 @@ * 1.00a rpoolla 04/26/13 First release * 1.02a hk 10/28/13 Added API to read status register.PR# 735957 * 2.00 hk 23/01/14 Changed PS efuse error codes for voltage out of range. +* 2.1 sk 04/03/15 Initialized RSAKeyReadback with Zeros CR# 829723. * * *****************************************************************************/ @@ -316,6 +317,7 @@ u32 XilSKey_EfusePs_Read(XilSKey_EPs *InstancePtr) u32 Status, RetValue; u32 RefClk; u32 ArmPllFDiv,ArmClkDivisor; + u32 Index; RetValue = XST_SUCCESS; @@ -324,6 +326,14 @@ u32 XilSKey_EfusePs_Read(XilSKey_EPs *InstancePtr) return XSK_EFUSEPS_ERROR_PS_STRUCT_NULL; } + /* Initializing RSAKeyReadback to Zero since when reading + * the key with XSK_EFUSEPS_ENABLE_RSA_KEY_HASH + * as FALSE it will give all zeros. + */ + for(Index = 0; Index < XSK_EFUSEPS_RSA_KEY_HASH_LEN_IN_BYTES; Index++) { + InstancePtr->RsaKeyReadback[Index] = 0; + } + /** * Extract PLL FDIV value from ARM PLL Control Register */