mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-01 18:50:34 +03:00
feat: added call to aquire clock source for H4 and H21 AES crypto
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
|
||||
#include "soc/soc.h"
|
||||
#include "soc/pcr_reg.h"
|
||||
#include "esp_private/esp_clk_tree_common.h"
|
||||
|
||||
#pragma once
|
||||
|
||||
@@ -16,6 +17,6 @@ void esp_crypto_common_clk_enable(bool enable);
|
||||
static inline void esp_crypto_clk_init(void)
|
||||
{
|
||||
// Set crypto clock (`clk_sec`) to use 96M PLL clock
|
||||
esp_clk_tree_enable_src(SOC_MOD_CLK_PLL_F96M, true);
|
||||
REG_SET_FIELD(PCR_SEC_CONF_REG, PCR_SEC_CLK_SEL, 0x3);
|
||||
// TODO: IDF-12266 need to call esp_clk_tree_enable_src() to acquire PLL 96M clock gating
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
|
||||
#include "soc/soc.h"
|
||||
#include "soc/pcr_reg.h"
|
||||
#include "esp_private/esp_clk_tree_common.h"
|
||||
|
||||
#pragma once
|
||||
|
||||
@@ -16,6 +17,6 @@ void esp_crypto_common_clk_enable(bool enable);
|
||||
static inline void esp_crypto_clk_init(void)
|
||||
{
|
||||
// Set crypto clock (`clk_sec`) to use 96M PLL clock
|
||||
esp_clk_tree_enable_src(SOC_MOD_CLK_PLL_F96M, true);
|
||||
REG_SET_FIELD(PCR_SEC_CONF_REG, PCR_SEC_CLK_SEL, 0x3);
|
||||
// TODO: IDF-12266 need to call esp_clk_tree_enable_src() to acquire PLL 96M clock gating
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user