diff options
author | Weijie Gao <weijie.gao@mediatek.com> | 2025-02-13 17:00:34 +0800 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2025-02-21 11:36:37 -0600 |
commit | f777cb8815baf1f002108cc8ecec525aa13b4f73 (patch) | |
tree | 9d88c33069d42337df179c387121eed2e28b6c4c | |
parent | 7fa38ae6c778eabe6ad055ec40402b1eab61a3a5 (diff) |
arm: mediatek: build u-boot-mtk.bin only if needed
Not all MediaTek platforms needs u-boot-mtk.bin.
This patch will let u-boot generates u-boot-mtk.bin only if
CONFIG_MTK_BROM_HEADER_INFO is not empty.
Signed-off-by: Weijie Gao <weijie.gao@mediatek.com>
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | arch/arm/mach-mediatek/Kconfig | 3 |
2 files changed, 3 insertions, 2 deletions
@@ -1016,8 +1016,10 @@ INPUTS-$(CONFIG_EFI_STUB) += u-boot-payload.efi # Generate this input file for binman ifeq ($(CONFIG_SPL),) +ifneq ($(patsubst "%",%,$(CONFIG_MTK_BROM_HEADER_INFO)),) INPUTS-$(CONFIG_ARCH_MEDIATEK) += u-boot-mtk.bin endif +endif # Add optional build target if defined in board/cpu/soc headers ifneq ($(CONFIG_BUILD_TARGET),) diff --git a/arch/arm/mach-mediatek/Kconfig b/arch/arm/mach-mediatek/Kconfig index 39eea055f70..673ceb1a093 100644 --- a/arch/arm/mach-mediatek/Kconfig +++ b/arch/arm/mach-mediatek/Kconfig @@ -160,9 +160,8 @@ config SYS_CONFIG_NAME config MTK_BROM_HEADER_INFO string - default "media=nor" if TARGET_MT8518 || TARGET_MT8512 || TARGET_MT7629 || TARGET_MT7622 + default "media=nor" if TARGET_MT8518 || TARGET_MT8512 || TARGET_MT7629 default "media=emmc" if TARGET_MT8516 || TARGET_MT8365 || TARGET_MT8183 - default "media=snand;nandinfo=2k+64" if TARGET_MT7981 || TARGET_MT7986 || TARGET_MT7987 || TARGET_MT7988 default "lk=1" if TARGET_MT7623 config MTK_TZ_MOVABLE |