Merge branch 'fix/align_sw_psa_drivers_and_hw_esp_psa_drivers_v6.1' into 'release/v6.1'

Align s/w and h/w PSA drivers (v6.1)

See merge request espressif/esp-idf!49704
This commit is contained in:
Mahavir Jain
2026-07-02 15:22:15 +05:30
25 changed files with 1157 additions and 596 deletions

View File

@@ -221,6 +221,10 @@ Using an eFuse-based HMAC key:
// failure calculating HMAC
}
.. note::
The ESP-HMAC opaque PSA driver is backed by the one-shot hardware HMAC peripheral, which computes the MAC over the whole message in a single operation and cannot save or restore intermediate state between calls. Multipart streaming is therefore not supported: supply the entire message in a single :cpp:func:`psa_mac_compute` call (as shown above) or in a single multipart update. A second non-empty update on the same operation returns ``PSA_ERROR_BAD_STATE``; the operation fails closed and never produces a MAC computed over only part of the message.
API Reference
-------------

View File

@@ -221,6 +221,10 @@ HMAC 的第三种应用场景是将其作为密钥,启用软禁用的 JTAG 接
// 计算 HMAC 失败
}
.. note::
ESP-HMAC 不透明 PSA 驱动基于单次硬件 HMAC 外设实现,该外设可以通过单次运算为完整消息计算消息认证码 (MAC),但无法在多次调用之间保存或恢复运算中间状态。因此,该驱动不支持多分段流式运算:须在单次 :cpp:func:`psa_mac_compute` 调用中传入完整消息(如上所示),或仅执行一次多分段更新操作。若对同一 MAC 运算操作发起第二次非空更新,会返回 ``PSA_ERROR_BAD_STATE`` 错误,且该操作会直接失败并关闭,不会基于部分消息生成对应的 MAC 结果。
API 参考
-------------