Skip to content

boot: bootutil: declare fih_panic_loop() as noreturn #2371

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 15, 2025

Conversation

etienne-lms
Copy link
Contributor

Add noreturn attribute the fih_panic_loop() and add a terminal endless loop in the function to prevent build warnings like the below one found when build MCUBOOT in TF-M:

.../arm-none-eabi/include/assert.h: In function '__assert_func':
.../trusted-firmware-m/platform/ext/common/tfm_assert.c:22:1: warning: 'noreturn' function does return
   22 | }
      | ^

Add noreturn attribute the fih_panic_loop() and add a terminal
endless loop in the function to prevent build warnings like
the below one found when build MCUBOOT in TF-M:

.../arm-none-eabi/include/assert.h: In function '__assert_func':
.../trusted-firmware-m/platform/ext/common/tfm_assert.c:22:1: warning: 'noreturn' function does return
   22 | }
      | ^

Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
@etienne-lms etienne-lms requested a review from davidvincze as a code owner July 3, 2025 08:41
etienne-lms added a commit to etienne-lms/trusted-firmware-m-zephyr that referenced this pull request Jul 11, 2025
Until the PR mcu-tools/mcuboot#2371 is merged,
apply the added patch to prevent build warning on FIH_PANIC.

Signed-off-by: Etienne Carriere <etienne.carriere@st.com>
@nordicjm nordicjm merged commit 3e02536 into mcu-tools:main Jul 15, 2025
58 checks passed
@etienne-lms etienne-lms deleted the fih-panic branch July 15, 2025 12:14
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.

3 participants