fix: disable bootloader variants for targets without storage backend#11522
Open
daijoubu wants to merge 1 commit intoiNavFlight:maintenance-9.xfrom
Open
fix: disable bootloader variants for targets without storage backend#11522daijoubu wants to merge 1 commit intoiNavFlight:maintenance-9.xfrom
daijoubu wants to merge 1 commit intoiNavFlight:maintenance-9.xfrom
Conversation
ANYFC, CLRACINGF4AIR (V1/V2/V3), FF_F35_LIGHTNING, WINGFC, FLYINGRCF4WINGMINI_NOT_RECOMMENDED, AIRBOTF7, and OMNIBUSF7NANOV7 all lack USE_FLASHFS/USE_SDCARD in their target config. Building _bl/_for_bl/_with_bl variants for these targets produces binaries that define MSP_FIRMWARE_UPDATE but have no storage backend, making OTA firmware update silently non-functional. Add NO_BOOTLOADER to cmake/stm32.cmake (following the DISABLE_MSC pattern) and set it on each affected target. This suppresses the broken bootloader build variants while leaving open the possibility of adding proper storage support to these targets in the future. Note: bootloader variants are not built by CI (they are not added to VALID_TARGETS), so this bug was never caught by automated builds. Fixes: iNavFlight#11521
|
Test firmware build ready — commit Download firmware for PR #11522 234 targets built. Find your board's
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Seven target configs (covering 9 build targets) have
BOOTLOADERenabled via their MCU family cmake function but define no storage backend (USE_FLASHFS/USE_SDCARD) intarget.h. This fails to build triggering a check for a storage backend in firmware_update_common.c and bl_main.c —MSP_FIRMWARE_UPDATErequires afatfs or a flash partition at runtime.Closes #11521
Changes
cmake/stm32.cmake: addNO_BOOTLOADERboolean flag (following the existingDISABLE_MSCpattern); guard bootloader variant build withif(args_BOOTLOADER AND NOT args_NO_BOOTLOADER)NO_BOOTLOADERon all affected targets:ANYFCCLRACINGF4AIR,CLRACINGF4AIRV2,CLRACINGF4AIRV3FF_F35_LIGHTNING,WINGFCFLYINGRCF4WINGMINI_NOT_RECOMMENDEDAIRBOTF7,OMNIBUSF7NANOV7The
NO_BOOTLOADERflag is intentionally a per-target opt-out rather than a cmake-level guard, so that adding storage support to any of these targets in the future automatically re-enables the bootloader build without further cmake changes.Testing
FF_F35_LIGHTNINGbuilds successfully (release target, good smoke test)ANYFCbuilds successfullyANYFC_blno longer exists as a build target (confirmed:No rule to make target 'ANYFC_bl')MATEKF765SEbuilds with bootloader support intact (regression check)Notes
Bootloader variants are not included in
VALID_TARGETSand are therefore never built by CI, which is why this has gone undetected.