mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-01 18:50:34 +03:00
refactor(flash_enc): move esp_flash_encryption_enabled() to efuse component
This commit is contained in:
committed by
Chen Ji Chang
parent
fea2c08655
commit
04df934c05
@@ -406,7 +406,7 @@ static esp_err_t check_and_generate_encryption_keys(void)
|
||||
|
||||
esp_err_t esp_flash_encrypt_init(void)
|
||||
{
|
||||
if (esp_flash_encryption_enabled()) {
|
||||
if (esp_efuse_is_flash_encryption_enabled()) {
|
||||
return ESP_OK;
|
||||
}
|
||||
|
||||
@@ -503,7 +503,7 @@ esp_err_t esp_flash_encrypt_contents(void)
|
||||
esp_err_t esp_flash_encrypt_enable(void)
|
||||
{
|
||||
esp_err_t err = ESP_OK;
|
||||
if (!esp_flash_encryption_enabled()) {
|
||||
if (!esp_efuse_is_flash_encryption_enabled()) {
|
||||
|
||||
if (esp_flash_encrypt_is_write_protected(true)) {
|
||||
return ESP_FAIL;
|
||||
|
||||
Reference in New Issue
Block a user