* [Buildroot] [PATCH] package/uboot-tools: fix dumpimage for FIT image
@ 2022-08-04 6:05 Atsushi Nemoto
2022-08-04 10:57 ` Thomas Petazzoni via buildroot
0 siblings, 1 reply; 3+ messages in thread
From: Atsushi Nemoto @ 2022-08-04 6:05 UTC (permalink / raw)
To: buildroot; +Cc: Fabrice Fontaine, Matt Weber, Yann E. MORIN
The upstream commit 7a01882eb37e7504e2450f474d0cc8db60ed26c2
("common: Kconfig.boot: Add FIT_PRINT config option") introduce
CONFIG_FIT_PRINT and make fit_print_contents() empty if it was
not enabled.
Add "#define CONFIG_FIT_PRINT 1" to autoconf.h if FIT_SUPPORT enabled.
Signed-off-by: Atsushi Nemoto <atsushi.nemoto@sord.co.jp>
---
Backport to: 2022.02.x, 2022.05.x
---
package/uboot-tools/uboot-tools.mk | 2 ++
1 file changed, 2 insertions(+)
diff --git a/package/uboot-tools/uboot-tools.mk b/package/uboot-tools/uboot-tools.mk
index 7cd527ad12..d884a010fb 100644
--- a/package/uboot-tools/uboot-tools.mk
+++ b/package/uboot-tools/uboot-tools.mk
@@ -22,6 +22,7 @@ define UBOOT_TOOLS_CONFIGURE_CMDS
touch $(@D)/include/config/auto.conf
mkdir -p $(@D)/include/generated
touch $(@D)/include/generated/autoconf.h
+ echo $(if $(BR2_PACKAGE_UBOOT_TOOLS_FIT_SUPPORT),'#define CONFIG_FIT_PRINT 1') >> $(@D)/include/generated/autoconf.h
mkdir -p $(@D)/include/asm
touch $(@D)/include/asm/linkage.h
endef
@@ -111,6 +112,7 @@ define HOST_UBOOT_TOOLS_CONFIGURE_CMDS
touch $(@D)/include/config/auto.conf
mkdir -p $(@D)/include/generated
touch $(@D)/include/generated/autoconf.h
+ echo $(if $(BR2_PACKAGE_HOST_UBOOT_TOOLS_FIT_SUPPORT),'#define CONFIG_FIT_PRINT 1') >> $(@D)/include/generated/autoconf.h
mkdir -p $(@D)/include/asm
touch $(@D)/include/asm/linkage.h
endef
--
2.30.2
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Buildroot] [PATCH] package/uboot-tools: fix dumpimage for FIT image
2022-08-04 6:05 [Buildroot] [PATCH] package/uboot-tools: fix dumpimage for FIT image Atsushi Nemoto
@ 2022-08-04 10:57 ` Thomas Petazzoni via buildroot
2022-08-04 11:58 ` Atsushi Nemoto
0 siblings, 1 reply; 3+ messages in thread
From: Thomas Petazzoni via buildroot @ 2022-08-04 10:57 UTC (permalink / raw)
To: Atsushi Nemoto; +Cc: Matt Weber, Fabrice Fontaine, Yann E. MORIN, buildroot
Hello,
On Thu, 04 Aug 2022 15:05:30 +0900 (JST)
Atsushi Nemoto <atsushi.nemoto@sord.co.jp> wrote:
> diff --git a/package/uboot-tools/uboot-tools.mk b/package/uboot-tools/uboot-tools.mk
> index 7cd527ad12..d884a010fb 100644
> --- a/package/uboot-tools/uboot-tools.mk
> +++ b/package/uboot-tools/uboot-tools.mk
> @@ -22,6 +22,7 @@ define UBOOT_TOOLS_CONFIGURE_CMDS
> touch $(@D)/include/config/auto.conf
> mkdir -p $(@D)/include/generated
> touch $(@D)/include/generated/autoconf.h
> + echo $(if $(BR2_PACKAGE_UBOOT_TOOLS_FIT_SUPPORT),'#define CONFIG_FIT_PRINT 1') >> $(@D)/include/generated/autoconf.h
> mkdir -p $(@D)/include/asm
> touch $(@D)/include/asm/linkage.h
> endef
> @@ -111,6 +112,7 @@ define HOST_UBOOT_TOOLS_CONFIGURE_CMDS
> touch $(@D)/include/config/auto.conf
> mkdir -p $(@D)/include/generated
> touch $(@D)/include/generated/autoconf.h
> + echo $(if $(BR2_PACKAGE_HOST_UBOOT_TOOLS_FIT_SUPPORT),'#define CONFIG_FIT_PRINT 1') >> $(@D)/include/generated/autoconf.h
> mkdir -p $(@D)/include/asm
> touch $(@D)/include/asm/linkage.h
> endef
Thanks for the bug report and proposed fix! Could we try to keep this
in the style of what is already done in the package, so something like
this:
diff --git a/package/uboot-tools/uboot-tools.mk b/package/uboot-tools/uboot-tools.mk
index 7cd527ad12..b6429cbbed 100644
--- a/package/uboot-tools/uboot-tools.mk
+++ b/package/uboot-tools/uboot-tools.mk
@@ -33,7 +33,7 @@ UBOOT_TOOLS_MAKE_OPTS = CROSS_COMPILE="$(TARGET_CROSS)" \
STRIP=$(TARGET_STRIP)
ifeq ($(BR2_PACKAGE_UBOOT_TOOLS_FIT_SUPPORT),y)
-UBOOT_TOOLS_MAKE_OPTS += CONFIG_FIT=y CONFIG_MKIMAGE_DTC_PATH=dtc
+UBOOT_TOOLS_MAKE_OPTS += CONFIG_FIT=y CONFIG_FIT_PRINT=y CONFIG_MKIMAGE_DTC_PATH=dtc
UBOOT_TOOLS_DEPENDENCIES += dtc
endif
@@ -121,7 +121,7 @@ HOST_UBOOT_TOOLS_MAKE_OPTS = HOSTCC="$(HOSTCC)" \
CONFIG_EFI_HAVE_CAPSULE_SUPPORT=y
ifeq ($(BR2_PACKAGE_HOST_UBOOT_TOOLS_FIT_SUPPORT),y)
-HOST_UBOOT_TOOLS_MAKE_OPTS += CONFIG_FIT=y CONFIG_MKIMAGE_DTC_PATH=dtc
+HOST_UBOOT_TOOLS_MAKE_OPTS += CONFIG_FIT=y CONFIG_FIT_PRINT=y CONFIG_MKIMAGE_DTC_PATH=dtc
HOST_UBOOT_TOOLS_DEPENDENCIES += host-dtc
endif
Could you check if this works for your use-case?
Thanks!
Thomas
--
Thomas Petazzoni, co-owner and CEO, Bootlin
Embedded Linux and Kernel engineering and training
https://bootlin.com
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [Buildroot] [PATCH] package/uboot-tools: fix dumpimage for FIT image
2022-08-04 10:57 ` Thomas Petazzoni via buildroot
@ 2022-08-04 11:58 ` Atsushi Nemoto
0 siblings, 0 replies; 3+ messages in thread
From: Atsushi Nemoto @ 2022-08-04 11:58 UTC (permalink / raw)
To: thomas.petazzoni
Cc: matthew.weber, fontaine.fabrice, yann.morin.1998, buildroot
On Thu, 4 Aug 2022 12:57:07 +0200, Thomas Petazzoni <thomas.petazzoni@bootlin.com> wrote:
> Thanks for the bug report and proposed fix! Could we try to keep this
> in the style of what is already done in the package, so something like
> this:
>
> diff --git a/package/uboot-tools/uboot-tools.mk b/package/uboot-tools/uboot-tools.mk
> index 7cd527ad12..b6429cbbed 100644
> --- a/package/uboot-tools/uboot-tools.mk
> +++ b/package/uboot-tools/uboot-tools.mk
> @@ -33,7 +33,7 @@ UBOOT_TOOLS_MAKE_OPTS = CROSS_COMPILE="$(TARGET_CROSS)" \
> STRIP=$(TARGET_STRIP)
>
> ifeq ($(BR2_PACKAGE_UBOOT_TOOLS_FIT_SUPPORT),y)
> -UBOOT_TOOLS_MAKE_OPTS += CONFIG_FIT=y CONFIG_MKIMAGE_DTC_PATH=dtc
> +UBOOT_TOOLS_MAKE_OPTS += CONFIG_FIT=y CONFIG_FIT_PRINT=y CONFIG_MKIMAGE_DTC_PATH=dtc
> UBOOT_TOOLS_DEPENDENCIES += dtc
> endif
Unfortunately this does not work as expected. Yes, I tried it first.
Maybe CONFIG_FIT_PRINT=y affects Makefiles only, not C sources.
---
Atsushi Nemoto
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2022-08-04 11:58 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-08-04 6:05 [Buildroot] [PATCH] package/uboot-tools: fix dumpimage for FIT image Atsushi Nemoto
2022-08-04 10:57 ` Thomas Petazzoni via buildroot
2022-08-04 11:58 ` Atsushi Nemoto
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox