diff options
author | Simon Glass | 2021-11-12 12:28:11 -0700 |
---|---|---|
committer | Simon Glass | 2022-01-26 08:50:44 -0700 |
commit | c033dc8c0c4b744e028e124f88be4829309c75d1 (patch) | |
tree | 8b29d79edab956df71ecf9529f34b102842b54be /tools/image-host.c | |
parent | 99f844ba3a6b3ddd73742cddf7dee955bbb96c61 (diff) |
image: Return destination node for add_verify_data() method
It is useful to know where the verification data was written. Update the
API to return this.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'tools/image-host.c')
-rw-r--r-- | tools/image-host.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/tools/image-host.c b/tools/image-host.c index f13a9441364..89520915aff 100644 --- a/tools/image-host.c +++ b/tools/image-host.c @@ -267,7 +267,7 @@ static int fit_image_process_sig(const char *keydir, const char *keyfile, */ if (keydest) { ret = info.crypto->add_verify_data(&info, keydest); - if (ret) { + if (ret < 0) { printf("Failed to add verification data for '%s' signature node in '%s' image node\n", node_name, image_name); return ret; @@ -1037,11 +1037,10 @@ static int fit_config_process_sig(const char *keydir, const char *keyfile, /* Write the public key into the supplied FDT file */ if (keydest) { ret = info.crypto->add_verify_data(&info, keydest); - if (ret) { + if (ret < 0) { printf("Failed to add verification data for '%s' signature node in '%s' configuration node\n", node_name, conf_name); } - return ret; } return 0; |