All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH] board/BuR/common: incorrect check of dtb
@ 2017-05-03 21:44 Heinrich Schuchardt
  2017-05-04 10:35 ` Hannes Schmelzer
  2017-05-05 16:38 ` [U-Boot] " Tom Rini
  0 siblings, 2 replies; 9+ messages in thread
From: Heinrich Schuchardt @ 2017-05-03 21:44 UTC (permalink / raw)
  To: u-boot

The logical expression to check the dtb is incorrect in
load_devicetree.

The problem was indicated by cppcheck.

Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
---
I do not have a board for testing.
Please, review carefully.
---
 board/BuR/common/common.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/board/BuR/common/common.c b/board/BuR/common/common.c
index 876150402c..c0316b9ebd 100644
--- a/board/BuR/common/common.c
+++ b/board/BuR/common/common.c
@@ -265,7 +265,7 @@ static int load_devicetree(void)
 	char *dtbname = getenv("dtb");
 	char *dtbdev = getenv("dtbdev");
 	char *dtppart = getenv("dtbpart");
-	if (!dtbdev || !dtbdev || !dtbname) {
+	if (!dtbdev || !dtbpart || !dtbname) {
 		printf("%s: <dtbdev>/<dtbpart>/<dtb> missing.\n", __func__);
 		return -1;
 	}
-- 
2.11.0

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2017-05-07  1:28 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-03 21:44 [U-Boot] [PATCH] board/BuR/common: incorrect check of dtb Heinrich Schuchardt
2017-05-04 10:35 ` Hannes Schmelzer
2017-05-05 16:38 ` [U-Boot] " Tom Rini
2017-05-05 18:11   ` Anatolij Gustschin
2017-05-05 18:14     ` Tom Rini
2017-05-05 18:44       ` Hannes Schmelzer
2017-05-05 18:57         ` [U-Boot] [PATCH v2 1/1] " Heinrich Schuchardt
2017-05-05 19:45           ` Hannes Schmelzer
2017-05-07  1:28           ` [U-Boot] [U-Boot, v2, " Tom Rini

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.