Skip to content

Revert "add support for STM32L443RC & WISE-1510" #5977

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

12 changes: 6 additions & 6 deletions features/mbedtls/targets/TARGET_STM/aes_alt.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@

#if defined(MBEDTLS_AES_ALT)

#if defined(TARGET_STM32L486xG) || defined (TARGET_STM32L443xC)
#if defined(TARGET_STM32L486xG)
//the following defines are provided to maintain compatibility between STM32 families
#define __HAL_RCC_CRYP_CLK_ENABLE __HAL_RCC_AES_CLK_ENABLE
#define __HAL_RCC_CRYP_FORCE_RESET __HAL_RCC_AES_FORCE_RESET
Expand All @@ -39,7 +39,7 @@ static int aes_set_key( mbedtls_aes_context *ctx, const unsigned char *key, unsi
memcpy(ctx->aes_key, key, 16);
break;
case 192:
#if defined (TARGET_STM32L486xG) || defined (TARGET_STM32L443xC)
#if defined (TARGET_STM32L486xG)
return(MBEDTLS_ERR_AES_INVALID_KEY_LENGTH);
#else
ctx->hcryp_aes.Init.KeySize = CRYP_KEYSIZE_192B;
Expand All @@ -64,7 +64,7 @@ static int aes_set_key( mbedtls_aes_context *ctx, const unsigned char *key, unsi
__HAL_RCC_CRYP_CLK_ENABLE();

ctx->hcryp_aes.Init.pKey = ctx->aes_key;
#if defined (TARGET_STM32L486xG) || defined (TARGET_STM32L443xC)
#if defined (TARGET_STM32L486xG)
ctx->hcryp_aes.Init.KeyWriteFlag = CRYP_KEY_WRITE_ENABLE;
#endif
if (HAL_CRYP_Init(&ctx->hcryp_aes) == HAL_ERROR)
Expand Down Expand Up @@ -149,7 +149,7 @@ int mbedtls_aes_crypt_ecb( mbedtls_aes_context *ctx,
}

#if defined(MBEDTLS_CIPHER_MODE_CBC)
#if defined (TARGET_STM32L486xG) || defined (TARGET_STM32L443xC)
#if defined (TARGET_STM32L486xG)
static int st_cbc_restore_context(mbedtls_aes_context *ctx){
uint32_t tickstart;
tickstart = HAL_GetTick();
Expand Down Expand Up @@ -194,7 +194,7 @@ static int st_cbc_restore_context(mbedtls_aes_context *ctx){
return 0;
}

#endif /* TARGET_STM32L486xG || TARGET_STM32L443xC */
#endif /* TARGET_STM32L486xG */

int mbedtls_aes_crypt_cbc( mbedtls_aes_context *ctx,
int mode,
Expand All @@ -211,7 +211,7 @@ int mbedtls_aes_crypt_cbc( mbedtls_aes_context *ctx,
if (st_cbc_restore_context(ctx) != 0)
return (ST_ERR_AES_BUSY);

#if defined (TARGET_STM32L486xG) || defined (TARGET_STM32L443xC)
#if defined (TARGET_STM32L486xG)

if( mode == MBEDTLS_AES_DECRYPT ) {
if (st_hal_cryp_cbc(ctx, CRYP_ALGOMODE_KEYDERIVATION_DECRYPT, length, iv, (uint8_t *)input, (uint8_t *)output) != 0)
Expand Down

This file was deleted.

Loading