diff options
| author | James Hilliard <[email protected]> | 2026-06-25 18:18:21 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2026-07-13 17:06:29 -0600 |
| commit | 58c2284a1a90d138f60364caf3513dda5693f8ff (patch) | |
| tree | 8b9916531ab53dd371d7ce46af5bb28b4bf27b4d /include | |
| parent | 02f8b8ab6d6095dccf867d899099322f7430d20d (diff) | |
cmd: fdt: keep control FDT during checksign
The fdt checksign command accepts an optional address for an FDT
containing public keys. It currently installs that blob as gd->fdt_blob
before verifying the FIT configuration.
This breaks verification with DM-backed crypto drivers which have not
probed yet, since the later probe path expects gd->fdt_blob to remain
U-Boot's control FDT. For example, an ECDSA verifier can be bound from
the control FDT but fail to probe after fdt checksign points
gd->fdt_blob at the key-only DTB.
Add a FIT config verification helper that takes the key blob explicitly
and use it from fdt checksign. This keeps gd->fdt_blob unchanged while
still allowing the command to verify against an external key DTB.
Signed-off-by: James Hilliard <[email protected]>
Diffstat (limited to 'include')
| -rw-r--r-- | include/image.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/image.h b/include/image.h index 9c8a746d576..4b3c9c87bf5 100644 --- a/include/image.h +++ b/include/image.h @@ -1461,11 +1461,20 @@ int fit_image_verify_with_data(const void *fit, int image_noffset, int fit_image_verify(const void *fit, int noffset); #if CONFIG_IS_ENABLED(FIT_SIGNATURE) int fit_config_verify(const void *fit, int conf_noffset); +int fit_config_verify_with_key_blob(const void *fit, int conf_noffset, + const void *key_blob); #else static inline int fit_config_verify(const void *fit, int conf_noffset) { return 0; } + +static inline int fit_config_verify_with_key_blob(const void *fit, + int conf_noffset, + const void *key_blob) +{ + return 0; +} #endif int fit_all_image_verify(const void *fit); int fit_config_decrypt(const void *fit, int conf_noffset); |
