From d573efa8c65c966a4ea037f8f17f5fb9b3babe6f Mon Sep 17 00:00:00 2001 From: Daniele Lacamera Date: Fri, 24 May 2024 13:23:22 +0200 Subject: [PATCH] Initialize wolfPKCS11 also in "_hwswap" mode --- src/update_flash_hwswap.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/update_flash_hwswap.c b/src/update_flash_hwswap.c index 14db052c1..d2f758be6 100644 --- a/src/update_flash_hwswap.c +++ b/src/update_flash_hwswap.c @@ -27,6 +27,9 @@ #include "hal.h" #include "spi_flash.h" #include "wolfboot/wolfboot.h" +#ifdef SECURE_PKCS11 +int WP11_Library_Init(void); +#endif extern void hal_flash_dualbank_swap(void); @@ -92,6 +95,9 @@ void RAMFUNCTION wolfBoot_start(void) hal_flash_lock(); } } +#ifdef SECURE_PKCS11 + WP11_Library_Init(); +#endif hal_prepare_boot(); do_boot((void *)(WOLFBOOT_PARTITION_BOOT_ADDRESS + IMAGE_HEADER_SIZE)); }