summaryrefslogtreecommitdiff
path: root/include/image.h
diff options
context:
space:
mode:
authorPhilippe Reynes <[email protected]>2022-03-28 22:57:02 +0200
committerTom Rini <[email protected]>2022-03-31 14:12:01 -0400
commit6e052d1cbafbedbfba73070da483111f2ae68e5a (patch)
tree00a472ea1ce0019a08f16668b039468dbde90ac1 /include/image.h
parent2404a01544e5b4a70c2f5e07f0c915743995ffea (diff)
mkimage: add public key for image pre-load stage
This commit enhances mkimage to update the node /image/pre-load/sig with the public key. Reviewed-by: Simon Glass <[email protected]> Signed-off-by: Philippe Reynes <[email protected]>
Diffstat (limited to 'include/image.h')
-rw-r--r--include/image.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/include/image.h b/include/image.h
index 496b7af3f36..498eb7f2e3e 100644
--- a/include/image.h
+++ b/include/image.h
@@ -1019,6 +1019,21 @@ int fit_image_hash_get_value(const void *fit, int noffset, uint8_t **value,
int fit_set_timestamp(void *fit, int noffset, time_t timestamp);
+/**
+ * fit_pre_load_data() - add public key to fdt blob
+ *
+ * Adds public key to the node pre load.
+ *
+ * @keydir: Directory containing keys
+ * @keydest: FDT blob to write public key
+ * @fit: Pointer to the FIT format image header
+ *
+ * returns:
+ * 0, on success
+ * < 0, on failure
+ */
+int fit_pre_load_data(const char *keydir, void *keydest, void *fit);
+
int fit_cipher_data(const char *keydir, void *keydest, void *fit,
const char *comment, int require_keys,
const char *engine_id, const char *cmdname);