Skip to content

Added boot benchmark support to update_flash.c#759

Open
dgarske wants to merge 1 commit intowolfSSL:masterfrom
dgarske:vorago_demo2
Open

Added boot benchmark support to update_flash.c#759
dgarske wants to merge 1 commit intowolfSSL:masterfrom
dgarske:vorago_demo2

Conversation

@dgarske
Copy link
Copy Markdown
Member

@dgarske dgarske commented Apr 26, 2026

No description provided.

@dgarske dgarske self-assigned this Apr 26, 2026
Copilot AI review requested due to automatic review settings April 26, 2026 00:00
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds BOOT_BENCHMARK instrumentation to the flash-based boot path so integrity and signature verification steps can be timed, and provides a VA416x0 HAL microsecond timer implementation plus an example config toggle.

Changes:

  • Add BENCHMARK_* hooks around integrity and signature verification in wolfBoot_start() for update_flash.
  • Implement hal_get_timer_us() for VA416x0 using SysTick + HAL_time_ms when BOOT_BENCHMARK (or disk update) is enabled.
  • Document the optional BOOT_BENCHMARK config toggle in the VA416x0 example config.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
src/update_flash.c Adds benchmark timing/logging around integrity and signature checks during flash boot.
hal/va416x0.c Adds a microsecond timer function used by benchmarking (and disk-update builds).
config/examples/vorago_va416x0.config Documents how to enable boot benchmarking for the VA416x0 example target.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/update_flash.c
Comment on lines +1489 to +1495
BENCHMARK_END("done");
}
if (bootRet >= 0) {
wolfBoot_printf("Verifying signature...");
BENCHMARK_START();
bootRet = wolfBoot_verify_authenticity(&boot);
BENCHMARK_END("done");
Comment thread hal/va416x0.c
Comment on lines +596 to +599
uint32_t val = SysTick->VAL;
uint32_t elapsed_ticks = load - val;

return (HAL_time_ms * 1000ULL) +
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants