devicetree-compiler.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] libfdt: Correct condition for reordering blocks
@ 2020-06-15 16:00 Simon Glass
       [not found] ` <20200615160033.87328-1-sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
  0 siblings, 1 reply; 2+ messages in thread
From: Simon Glass @ 2020-06-15 16:00 UTC (permalink / raw)
  To: Devicetree Compiler
  Cc: David Gibson, Rob Herring, Simon Glass, kernel test robot

This condition uses bitwise OR but should be logical OR. Fix it.

Signed-off-by: Simon Glass <sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
Reported-by: kernel test robot <lkp-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
---

 libfdt/fdt_rw.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libfdt/fdt_rw.c b/libfdt/fdt_rw.c
index 524b520..93e4a2b 100644
--- a/libfdt/fdt_rw.c
+++ b/libfdt/fdt_rw.c
@@ -436,7 +436,7 @@ int fdt_open_into(const void *fdt, void *buf, int bufsize)
 			return struct_size;
 	}
 
-	if (can_assume(LIBFDT_ORDER) |
+	if (can_assume(LIBFDT_ORDER) ||
 	    !fdt_blocks_misordered_(fdt, mem_rsv_size, struct_size)) {
 		/* no further work necessary */
 		err = fdt_move(fdt, buf, bufsize);
-- 
2.27.0.290.gba653c62da-goog


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

end of thread, other threads:[~2020-06-16  3:13 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-06-15 16:00 [PATCH] libfdt: Correct condition for reordering blocks Simon Glass
     [not found] ` <20200615160033.87328-1-sjg-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2020-06-16  3:13   ` David Gibson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).