summaryrefslogtreecommitdiff
path: root/lib/aes/aes-encrypt.c
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2024-12-19 09:10:48 -0600
committerTom Rini <trini@konsulko.com>2024-12-19 09:14:34 -0600
commit078542c346347406cfacdec8adeac66ae6758880 (patch)
tree9f9595f90f31df739d496f2f460b7142d7f9d939 /lib/aes/aes-encrypt.c
parent337bfdce5aa52637b482b182db959b9bb058f4b7 (diff)
parente7d7d3307c6109f2bec5dd5ba779996dd891348d (diff)
Merge branch '2024-12-19-assorted-tooling-updates' into next
This brings in assortment of updates to our python tooling, from Paul HENRYS <paul.henrys_ext@softathome.com>
Diffstat (limited to 'lib/aes/aes-encrypt.c')
-rw-r--r--lib/aes/aes-encrypt.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/aes/aes-encrypt.c b/lib/aes/aes-encrypt.c
index e74e35eaa28..90e1407b4f0 100644
--- a/lib/aes/aes-encrypt.c
+++ b/lib/aes/aes-encrypt.c
@@ -84,6 +84,13 @@ int image_aes_add_cipher_data(struct image_cipher_info *info, void *keydest,
char name[128];
int ret = 0;
+ if (!keydest && !info->ivname) {
+ /* At least, store the IV in the FIT image */
+ ret = fdt_setprop(fit, node_noffset, "iv",
+ info->iv, info->cipher->iv_len);
+ goto done;
+ }
+
/* Either create or overwrite the named cipher node */
parent = fdt_subnode_offset(keydest, 0, FIT_CIPHER_NODENAME);
if (parent == -FDT_ERR_NOTFOUND) {