projects
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c52bd03
)
cmd: fdt: Correct checking of configuration node
author
Bin Meng
<bmeng@tinylab.org>
Mon, 1 May 2023 03:35:25 +0000
(11:35 +0800)
committer
Tom Rini
<trini@konsulko.com>
Wed, 31 May 2023 21:23:01 +0000
(17:23 -0400)
fit_conf_get_node() returns a negative value on error.
Signed-off-by: Bin Meng <bmeng@tinylab.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
cmd/fdt.c
patch
|
blob
|
history
diff --git
a/cmd/fdt.c
b/cmd/fdt.c
index aae3278526c4a34efac461834687d36e55712327..2401ea8b44cbcf82d8c38d89ddd1e4674d9c7bbe 100644
(file)
--- a/
cmd/fdt.c
+++ b/
cmd/fdt.c
@@
-733,7
+733,7
@@
static int do_fdt(struct cmd_tbl *cmdtp, int flag, int argc, char *const argv[])
gd->fdt_blob = blob;
cfg_noffset = fit_conf_get_node(working_fdt, NULL);
- if (
!cfg_noffset
) {
+ if (
cfg_noffset < 0
) {
printf("Could not find configuration node: %s\n",
fdt_strerror(cfg_noffset));
return CMD_RET_FAILURE;