[bsp][stm32][prefect] avoid a bug from HAL

This commit is contained in:
Ernest 2019-07-12 15:10:10 +08:00
parent 3211ae2c16
commit 7b7443bb7b
1 changed files with 1 additions and 0 deletions

View File

@ -224,6 +224,7 @@ static void _crypto_destroy(struct rt_hwcrypto_ctx *ctx)
#if defined(BSP_USING_CRC) #if defined(BSP_USING_CRC)
case HWCRYPTO_TYPE_CRC: case HWCRYPTO_TYPE_CRC:
__HAL_CRC_DR_RESET((CRC_HandleTypeDef *)ctx-> contex);
HAL_CRC_DeInit((CRC_HandleTypeDef *)(ctx->contex)); HAL_CRC_DeInit((CRC_HandleTypeDef *)(ctx->contex));
break; break;
#endif /* BSP_USING_CRC */ #endif /* BSP_USING_CRC */