[bsp][stm32][drv_crypto] Enable RNG Clock

This commit is contained in:
Wu Han 2022-05-08 11:34:37 +01:00 committed by guo
parent 73236a825c
commit 4171fcbb06
1 changed files with 1 additions and 0 deletions

View File

@ -395,6 +395,7 @@ static rt_err_t _crypto_create(struct rt_hwcrypto_ctx *ctx)
#if defined(BSP_USING_RNG)
case HWCRYPTO_TYPE_RNG:
{
__HAL_RCC_RNG_CLK_ENABLE();
RNG_HandleTypeDef *hrng = rt_calloc(1, sizeof(RNG_HandleTypeDef));
if (RT_NULL == hrng)
{