[PATCH v2 0/3] mkimage: validate default configuration reference
Aristo Chen
jj251510319013 at gmail.com
Tue Jul 15 15:03:04 CEST 2025
This patch series introduces a validation step in `mkimage` to ensure that
the `default` property under the `/configurations` node in a FIT image
references a valid subnode. If the referenced node does not exist, mkimage
now prints an error and fails early. This helps prevent runtime failures
when U-Boot attempts to boot using an undefined configuration.
The first patch implements the validation logic in `fit_image.c`. The second
patch fixes an invalid default configuration reference exposed by this new
check in the `k3-am65-iot2050-boot-image.dtsi`. The final patch adds a test
case to verify that mkimage correctly fails when an invalid default
configuration is present in the ITS file.
This series improves the robustness of FIT image generation and helps
catch malformed image trees during build time.
### Changes in v2
- Modify the order of the commits, code is not changed
Aristo Chen (3):
arm: k3-am65-iot2050: Fix invalid default configuration reference
tools: fit_image: validate existence of default configuration node
test: fit: add test case for invalid default configuration reference
arch/arm/dts/k3-am65-iot2050-boot-image.dtsi | 4 +-
test/py/tests/test_fit_mkimage_validate.py | 45 ++++++++++++++++++++
tools/fit_image.c | 10 +++++
3 files changed, 57 insertions(+), 2 deletions(-)
--
2.43.0
More information about the U-Boot
mailing list