diff options
author | Bin Meng <bmeng@tinylab.org> | 2023-05-01 11:35:26 +0800 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2023-05-31 17:23:01 -0400 |
commit | 1310ad3aacf5cae97a2f3457ec9ef56f0d88bc09 (patch) | |
tree | e2054e1f677fbac4ca6a1828392a617d889617fa | |
parent | 33c63cea5ee13da6cc7c62443b1f953f74828302 (diff) | |
download | u-boot-1310ad3aacf5cae97a2f3457ec9ef56f0d88bc09.zip u-boot-1310ad3aacf5cae97a2f3457ec9ef56f0d88bc09.tar.gz u-boot-1310ad3aacf5cae97a2f3457ec9ef56f0d88bc09.tar.bz2 |
spl: Correct checking of configuration node
Per the fit_conf_get_node() API doc, it returns configuration node
offset when found (>=0).
Signed-off-by: Bin Meng <bmeng@tinylab.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
-rw-r--r-- | common/spl/spl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/common/spl/spl.c b/common/spl/spl.c index 72078a8..801c4b5 100644 --- a/common/spl/spl.c +++ b/common/spl/spl.c @@ -331,7 +331,7 @@ static int spl_load_fit_image(struct spl_image_info *spl_image, conf_noffset = fit_conf_get_node((const void *)header, fit_uname_config); - if (conf_noffset <= 0) + if (conf_noffset < 0) return 0; for (idx = 0; |