southbridge/intel: Set chipset in ifdtool invocations

Since IFD format is floating, ifdtool needs to be parameterized with a
chipset it is dealing with. Add -p <chipset> argument to ifdtool
invocations if chipset provides it.

Change-Id: I4fd1783b5d994617912aedcf17adc2a98c97227b
Signed-off-by: Andrey Petrov <andrey.petrov@intel.com>
Reviewed-on: https://review.coreboot.org/17258
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Martin Roth <martinroth@google.com>
This commit is contained in:
Andrey Petrov 2016-11-06 23:43:16 -08:00 committed by Martin Roth
parent 96ecb77905
commit c4d0f526d4
1 changed files with 11 additions and 3 deletions

View File

@ -33,6 +33,9 @@ IFD_SECTIONS := $(addprefix -b ,$(CONFIG_IFD_BIOS_SECTION:"%"=%)) \
$(addprefix -p ,$(CONFIG_IFD_PLATFORM_SECTION:"%"=%)) $(addprefix -p ,$(CONFIG_IFD_PLATFORM_SECTION:"%"=%))
else else
IFD_BIN_PATH := $(CONFIG_IFD_BIN_PATH) IFD_BIN_PATH := $(CONFIG_IFD_BIN_PATH)
ifneq ($(call strip_quotes,$(CONFIG_IFD_CHIPSET)),)
IFDTOOL_USE_CHIPSET := -p $(CONFIG_IFD_CHIPSET)
endif
endif endif
add_intel_firmware: $(obj)/coreboot.pre $(IFDTOOL) $(IFDFAKE) add_intel_firmware: $(obj)/coreboot.pre $(IFDTOOL) $(IFDFAKE)
@ -50,6 +53,7 @@ endif
ifeq ($(CONFIG_HAVE_ME_BIN),y) ifeq ($(CONFIG_HAVE_ME_BIN),y)
printf " IFDTOOL me.bin -> coreboot.pre\n" printf " IFDTOOL me.bin -> coreboot.pre\n"
$(objutil)/ifdtool/ifdtool \ $(objutil)/ifdtool/ifdtool \
$(IFDTOOL_USE_CHIPSET) \
-i ME:$(CONFIG_ME_BIN_PATH) \ -i ME:$(CONFIG_ME_BIN_PATH) \
$(obj)/coreboot.pre $(obj)/coreboot.pre
mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre
@ -57,23 +61,27 @@ endif
ifeq ($(CONFIG_HAVE_GBE_BIN),y) ifeq ($(CONFIG_HAVE_GBE_BIN),y)
printf " IFDTOOL gbe.bin -> coreboot.pre\n" printf " IFDTOOL gbe.bin -> coreboot.pre\n"
$(objutil)/ifdtool/ifdtool \ $(objutil)/ifdtool/ifdtool \
$(IFDTOOL_USE_CHIPSET) \
-i GbE:$(CONFIG_GBE_BIN_PATH) \ -i GbE:$(CONFIG_GBE_BIN_PATH) \
$(obj)/coreboot.pre $(obj)/coreboot.pre
mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre
endif endif
ifeq ($(CONFIG_LOCK_MANAGEMENT_ENGINE),y) ifeq ($(CONFIG_LOCK_MANAGEMENT_ENGINE),y)
printf " IFDTOOL Locking Management Engine\n" printf " IFDTOOL Locking Management Engine\n"
$(objutil)/ifdtool/ifdtool -l $(obj)/coreboot.pre $(objutil)/ifdtool/ifdtool \
$(IFDTOOL_USE_CHIPSET) -l $(obj)/coreboot.pre
mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre
else ifneq ($(CONFIG_BUILD_WITH_FAKE_IFD),y) else ifneq ($(CONFIG_BUILD_WITH_FAKE_IFD),y)
printf " IFDTOOL Unlocking Management Engine\n" printf " IFDTOOL Unlocking Management Engine\n"
$(objutil)/ifdtool/ifdtool -u $(obj)/coreboot.pre $(objutil)/ifdtool/ifdtool \
$(IFDTOOL_USE_CHIPSET) -u $(obj)/coreboot.pre
mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre
endif endif
ifeq ($(CONFIG_EM100),y) ifeq ($(CONFIG_EM100),y)
printf " IFDTOOL Setting EM100 mode\n" printf " IFDTOOL Setting EM100 mode\n"
$(objutil)/ifdtool/ifdtool --em100 $(obj)/coreboot.pre $(objutil)/ifdtool/ifdtool \
$(IFDTOOL_USE_CHIPSET) --em100 $(obj)/coreboot.pre
mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre mv $(obj)/coreboot.pre.new $(obj)/coreboot.pre
endif endif