From 07b7544094ff7d51c4f58e6631ba75b8814d665b Mon Sep 17 00:00:00 2001 From: Marco Oliverio Date: Tue, 18 Nov 2025 18:03:00 +0100 Subject: [PATCH 1/2] nvm: flash_log: fix include order not picking up settings --- wolfhsm/wh_nvm_flash_log.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wolfhsm/wh_nvm_flash_log.h b/wolfhsm/wh_nvm_flash_log.h index 42d879623..260a2dfce 100644 --- a/wolfhsm/wh_nvm_flash_log.h +++ b/wolfhsm/wh_nvm_flash_log.h @@ -19,10 +19,10 @@ #ifndef WOLFHSM_WH_NVM_FLASH_LOG_H_ #define WOLFHSM_WH_NVM_FLASH_LOG_H_ -#if defined(WOLFHSM_CFG_SERVER_NVM_FLASH_LOG) - #include "wolfhsm/wh_settings.h" +#if defined(WOLFHSM_CFG_SERVER_NVM_FLASH_LOG) + #include "wolfhsm/wh_common.h" #include "wolfhsm/wh_flash.h" From 6560cad01268381cd3f2e6ce361eed20fe73d1ff Mon Sep 17 00:00:00 2001 From: Marco Oliverio Date: Tue, 18 Nov 2025 18:03:32 +0100 Subject: [PATCH 2/2] fix: wrong #endif placement previous refactor leaves a spurious #endif that broke (at least) builds without WOLFSSL_CMAC --- src/wh_client_crypto.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/wh_client_crypto.c b/src/wh_client_crypto.c index 5b61db3e1..108be1d21 100644 --- a/src/wh_client_crypto.c +++ b/src/wh_client_crypto.c @@ -2823,6 +2823,7 @@ int wh_Client_AesGetKeyId(Aes* key, whNvmId* outId) *outId = WH_DEVCTX_TO_KEYID(key->devCtx); return WH_ERROR_OK; } +#endif /* !NO_AES */ #ifdef WOLFSSL_CMAC int wh_Client_CmacSetKeyId(Cmac* key, whNvmId keyId) @@ -2868,7 +2869,6 @@ int wh_Client_Cmac(whClientContext* ctx, Cmac* cmac, CmacType type, WH_DEBUG_CLIENT_VERBOSE("cmac key:%p key_len:%d in:%p in_len:%d out:%p out_len:%d " "keyId:%x\n", key, (int)keyLen, in, (int)inLen, outMac, (int)mac_len, key_id); -#endif /* Get data pointer */