aboutsummaryrefslogtreecommitdiff
path: root/cmd
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2020-05-24 17:38:21 -0600
committerBin Meng <bmeng.cn@gmail.com>2020-05-27 14:40:09 +0800
commit0e7b6312e7c6780381612fe09a73c77f77e63c2d (patch)
tree86bf311dd1e2de0b65cfce44d9e2968375b29690 /cmd
parentc685f8bcfcf097b1f46ea742a65765b7696a9a48 (diff)
downloadu-boot-0e7b6312e7c6780381612fe09a73c77f77e63c2d.zip
u-boot-0e7b6312e7c6780381612fe09a73c77f77e63c2d.tar.gz
u-boot-0e7b6312e7c6780381612fe09a73c77f77e63c2d.tar.bz2
cbfs: Return the error code from file_cbfs_init()
We may as well return the error code and use it directly in the command code. CBFS still uses its own error enum which we may be able to remove, but leave it for now. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'cmd')
-rw-r--r--cmd/cbfs.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/cmd/cbfs.c b/cmd/cbfs.c
index 8e91d4b..10c2c92 100644
--- a/cmd/cbfs.c
+++ b/cmd/cbfs.c
@@ -28,8 +28,7 @@ static int do_cbfs_init(struct cmd_tbl *cmdtp, int flag, int argc,
return 1;
}
}
- file_cbfs_init(end_of_rom);
- if (cbfs_get_result() != CBFS_SUCCESS) {
+ if (file_cbfs_init(end_of_rom)) {
printf("%s.\n", file_cbfs_error());
return 1;
}