Hung-Te Lin has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/46389 )
Change subject: soc/mediatek/mt8192: add spmfw loader ......................................................................
Patch Set 33:
(1 comment)
https://review.coreboot.org/c/coreboot/+/46389/33/src/soc/mediatek/mt8192/Ma... File src/soc/mediatek/mt8192/Makefile.inc:
https://review.coreboot.org/c/coreboot/+/46389/33/src/soc/mediatek/mt8192/Ma... PS33, Line 53: cbfs-files-y += spm_firmware.bin : spm_firmware.bin-file := $(MT8192_BLOB_DIR)/spm_firmware.bin : spm_firmware.bin-type := raw : spm_firmware.bin-compression := $(CBFS_COMPRESS_FLAG) If we will be adding a lot of firmware files like this, I think we should:
1. Define the blob name in Kconfig, say CONFIG_SPM_FIRMWARE = "spm_firmware.bin" 2. In *.c use CONFIG_SPM_FIRMWARE instead of putting another name there 3. Add a rule in Makefile.inc so we can easily add them, say
mcu-firmware-files += $(CONFIG_SPM_FIRMARE)
$(foreach fw, $(mcu-firmware-files), ... $(eval $(fw)-file := $(MT8192_BLOB_DIR)/$(fw)) ... )
Also we can add 'ifneq ($(wildcard ...))' so we won't see build failure even if the blobs don't exist.