diff options
author | xypron.glpk@gmx.de <xypron.glpk@gmx.de> | 2017-05-05 18:57:32 (GMT) |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2017-05-05 20:46:51 (GMT) |
commit | 169b50efe2635952d9679268860a3e37aa13adf6 (patch) | |
tree | be5c9f43edb8f996016124daeed05273feafbfe0 | |
parent | f59a3b21f60190793dc3cee97338c2f6ee9f2336 (diff) | |
download | u-boot-169b50efe2635952d9679268860a3e37aa13adf6.tar.xz |
board/BuR/common: incorrect check of dtb
The logical expression to check the dtb is incorrect in
load_devicetree.
The problem was indicated by cppcheck.
The inconsistent variable name dtppart is changed to dtbpart.
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Reviewed-by: Hannes Schmelzer <oe5hpm@oevsv.at>
Acked-by: Hannes Schmelzer <oe5hpm@oevsv.at>
-rw-r--r-- | board/BuR/common/common.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/board/BuR/common/common.c b/board/BuR/common/common.c index 8761504..5cc82c9 100644 --- a/board/BuR/common/common.c +++ b/board/BuR/common/common.c @@ -264,13 +264,13 @@ static int load_devicetree(void) #else char *dtbname = getenv("dtb"); char *dtbdev = getenv("dtbdev"); - char *dtppart = getenv("dtbpart"); - if (!dtbdev || !dtbdev || !dtbname) { + char *dtbpart = getenv("dtbpart"); + if (!dtbdev || !dtbpart || !dtbname) { printf("%s: <dtbdev>/<dtbpart>/<dtb> missing.\n", __func__); return -1; } - if (fs_set_blk_dev(dtbdev, dtppart, FS_TYPE_EXT)) { + if (fs_set_blk_dev(dtbdev, dtbpart, FS_TYPE_EXT)) { puts("load_devicetree: set_blk_dev failed.\n"); return -1; } |