Fred Reitberger has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/61972 )
Change subject: mb/amd/chausie: Add EC blob into CBFS ......................................................................
mb/amd/chausie: Add EC blob into CBFS
Add chausie EC blob into CBFS at specified location
Change-Id: I48de08a18054efbda655e1563a539ff2ba7a38a6 Signed-off-by: Fred Reitberger reitbergerfred@gmail.com --- M src/mainboard/amd/chausie/Kconfig M src/mainboard/amd/chausie/Makefile.inc M src/mainboard/amd/chausie/board.fmd 3 files changed, 31 insertions(+), 4 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/72/61972/1
diff --git a/src/mainboard/amd/chausie/Kconfig b/src/mainboard/amd/chausie/Kconfig index dc6e090..1d16e26 100644 --- a/src/mainboard/amd/chausie/Kconfig +++ b/src/mainboard/amd/chausie/Kconfig @@ -24,7 +24,6 @@ config AMD_FWM_POSITION_INDEX int default 3 if CHROMEOS - default 4 help TODO: might need to be adapted for better placement of files in cbfs
@@ -32,12 +31,28 @@ bool "Have Microchip EC firmware?" default n
+config CHAUSIE_MCHP_SIG_FILE + string + depends on CHAUSIE_HAVE_MCHP_FW + default "3rdparty/blobs/mainboard/amd/chausie/EC_chausie_sig.bin" + help + The EC sig blob is usually the first 4kByte of the stock + firmware image. + config CHAUSIE_MCHP_FW_FILE string depends on CHAUSIE_HAVE_MCHP_FW default "3rdparty/blobs/mainboard/amd/chausie/EC_chausie.bin" help - The EC firmware blob is usually the first 128kByte of the stock + The EC firmware blob is at the CHAUSIE_MCHP_FW_OFFSET offset of the + firmware image. + +config CHAUSIE_MCHP_FW_OFFSET + hex + depends on CHAUSIE_HAVE_MCHP_FW + default 0x400000 + help + The EC firmware blob is at the 4MByte offset of the stock firmware image.
config VBOOT diff --git a/src/mainboard/amd/chausie/Makefile.inc b/src/mainboard/amd/chausie/Makefile.inc index ca267ea..c31d7ec 100644 --- a/src/mainboard/amd/chausie/Makefile.inc +++ b/src/mainboard/amd/chausie/Makefile.inc @@ -14,7 +14,19 @@
ifeq ($(CONFIG_CHAUSIE_HAVE_MCHP_FW),y) $(call add_intermediate, add_mchp_fw) - $(CBFSTOOL) $(obj)/coreboot.pre write -r EC -f $(CONFIG_CHAUSIE_MCHP_FW_FILE) --fill-upward + $(CBFSTOOL) $(obj)/coreboot.pre write -r EC -f $(CONFIG_CHAUSIE_MCHP_SIG_FILE) --fill-upward + +# calculate the absolute position from the config offset +CHAUSIE_EC_POSITION=$(call int-add, \ + $(call int-subtract, 0xffffffff \ + $(call int-shift-left, \ + 0x80000 $(CONFIG_AMD_FWM_POSITION_INDEX))) $(CONFIG_CHAUSIE_MCHP_FW_OFFSET) 1) + +cbfs-files-y += apu/ecfw +apu/ecfw-file := $(CONFIG_CHAUSIE_MCHP_FW_FILE) +apu/ecfw-position := $(CHAUSIE_EC_POSITION) +apu/ecfw-type := raw + else files_added:: warn_no_mchp endif # CONFIG_CHAUSIE_HAVE_MCHP_FW diff --git a/src/mainboard/amd/chausie/board.fmd b/src/mainboard/amd/chausie/board.fmd index 442d80f..642d7b2 100644 --- a/src/mainboard/amd/chausie/board.fmd +++ b/src/mainboard/amd/chausie/board.fmd @@ -1,6 +1,6 @@ FLASH@0xFF000000 16M { BIOS { - EC 128K + EC 4K RW_MRC_CACHE 64K FMAP 4K COREBOOT(CBFS)