[U-Boot] [PATCH v2 1/7] tegra: Clarify generation of -nodtb file with OF_CONTROL
Masahiro Yamada
yamada.masahiro at socionext.com
Sun Jan 31 17:13:09 CET 2016
Hi Simon,
2016-01-29 12:24 GMT+09:00 Simon Glass <sjg at chromium.org>:
> Fix the ALL-y logic in the Makefile so that is clear that we always want
> the -nodtb file.
>
> Signed-off-by: Simon Glass <sjg at chromium.org>
> ---
This commit introduces a build error
for the combination of CONFIG_TEGRA=y and CONFIG_EMBED=y.
(and fixed by 4/7)
$ make beaver_defconfig
$ make menuconfig [ --> choose CONFIG_OF_EMBED]
$ make CROSS_COMPILE=arm-linux-gnueabi-
scripts/kconfig/conf --silentoldconfig Kconfig
CHK include/config.h
[ snip ]
CAT u-boot-nodtb-tegra.bin
make: *** No rule to make target `u-boot-dtb-tegra.bin', needed by `all'. Stop.
> Changes in v2:
> - Rewrite this commit based on tegra feedback
>
> Makefile | 15 +++++----------
> 1 file changed, 5 insertions(+), 10 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 06996d4..6b95e79 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -764,14 +764,8 @@ ALL-$(CONFIG_X86_RESET_VECTOR) += u-boot.rom
> endif
>
> # enable combined SPL/u-boot/dtb rules for tegra
> -ifneq ($(CONFIG_TEGRA),)
> -ifeq ($(CONFIG_SPL),y)
> -ifeq ($(CONFIG_OF_SEPARATE),y)
> -ALL-y += u-boot-dtb-tegra.bin
> -else
> -ALL-y += u-boot-nodtb-tegra.bin
> -endif
> -endif
> +ifeq ($(CONFIG_TEGRA)$(CONFIG_SPL),yy)
> +ALL-y += u-boot-nodtb-tegra.bin u-boot-dtb-tegra.bin
> endif
Judging from the discussion in v1,
ifeq ($(CONFIG_TEGRA)$(CONFIG_SPL),yy)
ALL-y += u-boot-nodtb-tegra.bin
ALL-$(CONFIG_OF_SEPARATE) += u-boot-dtb-tegra.bin
endif
would be better, I think.
> # Add optional build target if defined in board/cpu/soc headers
> @@ -1078,8 +1072,9 @@ u-boot-nodtb-tegra.bin: spl/u-boot-spl u-boot.bin FORCE
> $(call if_changed,pad_cat)
>
> ifeq ($(CONFIG_OF_SEPARATE),y)
> -u-boot-dtb-tegra.bin: u-boot-nodtb-tegra.bin dts/dt.dtb FORCE
> - $(call if_changed,cat)
> +OBJCOPYFLAGS_u-boot-dtb-tegra.bin = -O binary --pad-to=$(CONFIG_SYS_TEXT_BASE)
> +u-boot-dtb-tegra.bin: spl/u-boot-spl u-boot-dtb.bin FORCE
> + $(call if_changed,pad_cat)
> endif
> endif
>
ifdefs around build rules are unnecessary.
--
Best Regards
Masahiro Yamada
More information about the U-Boot
mailing list