libfdt: Warnings of signed/unsigned comparison

Hi all,
enabling binman pulls in libfdt, and that seems to have a lot of issues with comparing signed with unsigned values. Those are present upstream as well (dtc in general doesn't build with -Wsign-compare).
Is anyone looking into this already? Fix upstream? Can we ignore this downstream for the time being?
diff --git a/scripts/dtc/libfdt/Makefile.libfdt b/scripts/dtc/libfdt/Makefile.libfdt index e54639738c..b88b21c920 100644 --- a/scripts/dtc/libfdt/Makefile.libfdt +++ b/scripts/dtc/libfdt/Makefile.libfdt @@ -12,6 +12,8 @@ LIBFDT_SRCS = fdt.c fdt_ro.c fdt_wip.c fdt_sw.c fdt_rw.c fdt_strerror.c fdt_empt LIBFDT_OBJS = $(LIBFDT_SRCS:%.c=%.o) LIBFDT_LIB = libfdt-$(DTC_VERSION).$(SHAREDLIB_EXT)
+HOSTCFLAGS += -Wno-sign-compare + libfdt_clean: @$(VECHO) CLEAN "(libfdt)" rm -f $(STD_CLEANFILES:%=$(LIBFDT_dir)/%)
Jan

Hi Jan,
On Mon, 17 Aug 2020 at 02:35, Jan Kiszka jan.kiszka@siemens.com wrote:
Hi all,
enabling binman pulls in libfdt, and that seems to have a lot of issues with comparing signed with unsigned values. Those are present upstream as well (dtc in general doesn't build with -Wsign-compare).
Is anyone looking into this already? Fix upstream? Can we ignore this downstream for the time being?
I did send a patch upstream but it needed a lot of review and thought. If you are able to fix some/all of these upstream it would be great!
Regards, Simon
participants (2)
-
Jan Kiszka
-
Simon Glass