Yu-Ping Wu has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/84053?usp=email )
Change subject: soc/mediatek: Require MCU and DRAM blobs to exist ......................................................................
soc/mediatek: Require MCU and DRAM blobs to exist
When the config of MCU firmware blob such as CONFIG_SPM_FIRMWARE is non-empty, we should always expect the file to exist. Similarly, since the device is unlikely to boot without the DRAM blob (assuming MRC_CACHE doesn't contain valid memory training data), dram.elf should always exist as well.
Therefore, remove the check for the existence of the blobs. Build would fail if any of the blobs is missing.
Change-Id: I755e7c5a70b34b0c3d3915ab339c65263688aad7 Signed-off-by: Yu-Ping Wu yupingso@chromium.org --- M src/soc/mediatek/mt8188/Makefile.mk M src/soc/mediatek/mt8192/Makefile.mk M src/soc/mediatek/mt8195/Makefile.mk 3 files changed, 6 insertions(+), 12 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/53/84053/1
diff --git a/src/soc/mediatek/mt8188/Makefile.mk b/src/soc/mediatek/mt8188/Makefile.mk index 6a57da4..727b3f8 100644 --- a/src/soc/mediatek/mt8188/Makefile.mk +++ b/src/soc/mediatek/mt8188/Makefile.mk @@ -78,16 +78,14 @@ $(eval $(fw)-file := $(MT8188_BLOB_DIR)/$(fw)) \ $(eval $(fw)-type := raw) \ $(eval $(fw)-compression := LZ4) \ - $(if $(wildcard $($(fw)-file)), $(eval cbfs-files-y += $(fw)), ) \ + $(eval cbfs-files-y += $(fw)) \ )
DRAM_CBFS := $(CONFIG_CBFS_PREFIX)/dram $(DRAM_CBFS)-file := $(MT8188_BLOB_DIR)/dram.elf $(DRAM_CBFS)-type := stage $(DRAM_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) -ifneq ($(wildcard $($(DRAM_CBFS)-file)),) - cbfs-files-y += $(DRAM_CBFS) -endif +cbfs-files-y += $(DRAM_CBFS)
$(objcbfs)/bootblock.bin: $(objcbfs)/bootblock.raw.bin ./util/mtkheader/gen-bl-img.py mt8183 sf $< $@ diff --git a/src/soc/mediatek/mt8192/Makefile.mk b/src/soc/mediatek/mt8192/Makefile.mk index 4e35fe1..081a9a9 100644 --- a/src/soc/mediatek/mt8192/Makefile.mk +++ b/src/soc/mediatek/mt8192/Makefile.mk @@ -71,16 +71,14 @@ $(eval $(fw)-file := $(MT8192_BLOB_DIR)/$(fw)) \ $(eval $(fw)-type := raw) \ $(eval $(fw)-compression := LZ4) \ - $(if $(wildcard $($(fw)-file)), $(eval cbfs-files-y += $(fw)), ) \ + $(eval cbfs-files-y += $(fw)) \ )
DRAM_CBFS := $(CONFIG_CBFS_PREFIX)/dram $(DRAM_CBFS)-file := $(MT8192_BLOB_DIR)/dram.elf $(DRAM_CBFS)-type := stage $(DRAM_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) -ifneq ($(wildcard $($(DRAM_CBFS)-file)),) - cbfs-files-y += $(DRAM_CBFS) -endif +cbfs-files-y += $(DRAM_CBFS)
$(objcbfs)/bootblock.bin: $(objcbfs)/bootblock.raw.bin ./util/mtkheader/gen-bl-img.py mt8183 sf $< $@ diff --git a/src/soc/mediatek/mt8195/Makefile.mk b/src/soc/mediatek/mt8195/Makefile.mk index d1c1920..f91372a 100644 --- a/src/soc/mediatek/mt8195/Makefile.mk +++ b/src/soc/mediatek/mt8195/Makefile.mk @@ -87,16 +87,14 @@ $(eval $(fw)-file := $(MT8195_BLOB_DIR)/$(fw)) \ $(eval $(fw)-type := raw) \ $(eval $(fw)-compression := LZ4) \ - $(if $(wildcard $($(fw)-file)), $(eval cbfs-files-y += $(fw)), ) \ + $(eval cbfs-files-y += $(fw)) \ )
DRAM_CBFS := $(CONFIG_CBFS_PREFIX)/dram $(DRAM_CBFS)-file := $(MT8195_BLOB_DIR)/dram.elf $(DRAM_CBFS)-type := stage $(DRAM_CBFS)-compression := $(CBFS_PRERAM_COMPRESS_FLAG) -ifneq ($(wildcard $($(DRAM_CBFS)-file)),) - cbfs-files-y += $(DRAM_CBFS) -endif +cbfs-files-y += $(DRAM_CBFS)
$(objcbfs)/bootblock.bin: $(objcbfs)/bootblock.raw.bin ./util/mtkheader/gen-bl-img.py mt8183 sf $< $@