From 298d763003ff7ffb85d8df9c7fd6dabc6e99a34a Mon Sep 17 00:00:00 2001 From: Ashish Sharma Date: Thu, 2 Jul 2026 14:47:21 +0800 Subject: [PATCH 1/2] fix(esp_tee): release SHA held by HMAC after crypto peripheral reset --- .../esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c | 1 + 1 file changed, 1 insertion(+) diff --git a/components/esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c b/components/esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c index a80429d6ecf..8f858e63ffa 100644 --- a/components/esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c +++ b/components/esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c @@ -61,6 +61,7 @@ void esp_tee_soc_reset_crypto_peripherals(void) #if SOC_HMAC_SUPPORTED hmac_ll_enable_bus_clock(true); hmac_ll_reset_register(); + hmac_ll_clean(); hmac_ll_enable_bus_clock(false); #endif From a3398cb629a1d0c11c14ef2dbdfd633fe3b2b65f Mon Sep 17 00:00:00 2001 From: Ashish Sharma Date: Thu, 2 Jul 2026 14:49:15 +0800 Subject: [PATCH 2/2] fix(esp_tee): fixes double panic when ESP-TEE panics --- .../esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/components/esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c b/components/esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c index 8f858e63ffa..6ade697f6b1 100644 --- a/components/esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c +++ b/components/esp_tee/subproject/main/soc/common/esp_tee_crypto_reset.c @@ -29,8 +29,9 @@ #endif #include "esp_tee.h" +#include "esp_attr.h" -void esp_tee_soc_reset_crypto_peripherals(void) +void IRAM_ATTR esp_tee_soc_reset_crypto_peripherals(void) { /* Reset the crypto peripherals to a clean state and leave their clocks disabled; drivers re-enable on demand */ #if SOC_AES_SUPPORTED