diff --git a/components/hal/esp32h21/include/hal/ecdsa_ll.h b/components/hal/esp32h21/include/hal/ecdsa_ll.h index 1593e61d69..608cf19bc7 100644 --- a/components/hal/esp32h21/include/hal/ecdsa_ll.h +++ b/components/hal/esp32h21/include/hal/ecdsa_ll.h @@ -242,16 +242,6 @@ static inline void ecdsa_ll_set_k_type(ecdsa_sign_type_t type) } } -/** - * @brief Set the loop number value that is used for deterministic derivation of K - * - * @param loop_number Loop number for deterministic K - */ -static inline void ecdsa_ll_set_deterministic_loop(uint16_t loop_number) -{ - REG_SET_FIELD(ECDSA_CONF_REG, ECDSA_DETERMINISTIC_LOOP, loop_number); -} - /** * @brief Set the stage of ECDSA operation * @@ -409,17 +399,6 @@ static inline int ecdsa_ll_get_operation_result(void) return REG_GET_BIT(ECDSA_RESULT_REG, ECDSA_OPERATION_RESULT); } -/** - * @brief Check if the k value is greater than the curve order. - * - * @return 0, k value is not greater than the curve order. In this case, the k value is the set k value. - * @return 1, k value is greater than than the curve order. In this case, the k value is the set (k mod n). - */ -static inline int ecdsa_ll_check_k_value(void) -{ - return REG_GET_BIT(ECDSA_RESULT_REG, ECDSA_K_VALUE_WARNING); -} - /** * @brief Check if the ECDSA curves configuration is supported */ diff --git a/components/soc/esp32h21/include/soc/Kconfig.soc_caps.in b/components/soc/esp32h21/include/soc/Kconfig.soc_caps.in index 073b66ed79..4aac6c2869 100644 --- a/components/soc/esp32h21/include/soc/Kconfig.soc_caps.in +++ b/components/soc/esp32h21/include/soc/Kconfig.soc_caps.in @@ -747,6 +747,10 @@ config SOC_ECDSA_SUPPORT_DETERMINISTIC_MODE bool default y +config SOC_ECDSA_SUPPORT_HW_DETERMINISTIC_LOOP + bool + default y + config SOC_ECDSA_P192_CURVE_DEFAULT_DISABLED bool default y diff --git a/components/soc/esp32h21/include/soc/soc_caps.h b/components/soc/esp32h21/include/soc/soc_caps.h index 8b06f9c559..26945c5cc4 100644 --- a/components/soc/esp32h21/include/soc/soc_caps.h +++ b/components/soc/esp32h21/include/soc/soc_caps.h @@ -488,6 +488,7 @@ /*------------------------- ECDSA CAPS -------------------------*/ #define SOC_ECDSA_SUPPORT_EXPORT_PUBKEY (1) #define SOC_ECDSA_SUPPORT_DETERMINISTIC_MODE (1) +#define SOC_ECDSA_SUPPORT_HW_DETERMINISTIC_LOOP (1) #define SOC_ECDSA_P192_CURVE_DEFAULT_DISABLED (1) /*-------------------------- UART CAPS ---------------------------------------*/