forked from wolfSSL/wolfssl
Fix for older STM32Cube HAL that does not support hcryp->Init.HeaderWidthUnit
. ZD 19926.
This commit is contained in:
@ -479,7 +479,7 @@ int wc_Stm32_Aes_Init(Aes* aes, CRYP_HandleTypeDef* hcryp)
|
||||
hcryp->Init.pKey = (STM_CRYPT_TYPE*)aes->key;
|
||||
#ifdef STM32_HAL_V2
|
||||
hcryp->Init.DataWidthUnit = CRYP_DATAWIDTHUNIT_BYTE;
|
||||
#ifdef STM_CRYPT_HEADER_WIDTH
|
||||
#if defined(CRYP_HEADERWIDTHUNIT_BYTE) && defined(STM_CRYPT_HEADER_WIDTH)
|
||||
hcryp->Init.HeaderWidthUnit =
|
||||
(STM_CRYPT_HEADER_WIDTH == 4) ?
|
||||
CRYP_HEADERWIDTHUNIT_WORD :
|
||||
|
Reference in New Issue
Block a user