summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSubrata Banik <subratabanik@google.com>2024-08-08 16:55:08 +0530
committerSubrata Banik <subratabanik@google.com>2024-08-09 09:28:12 +0000
commitf6efa4a345e6e2cb778f4898730aec6f043d7121 (patch)
tree08bac97ad88e08b8fe4c4d4efe06319df9c75906
parentab1d04a0c4d24073eb5bb324260f3fe78b992fea (diff)
soc/intel/cmn/block/cse: Add support for explicit CSE_RW_VERSION
This change adds support for specifying the CSE_RW_VERSION directly in Kconfig. * If `CONFIG_SOC_INTEL_CSE_RW_VERSION` is defined, its value will be used directly as the CSE_RW version. * Otherwise, the version will be extracted from the CSE_RW binary file as before. Platform prior to Intel Meteor Lake still requires to override the CSE RW version using CONFIG_SOC_INTEL_CSE_RW_VERSION config rather reading the CSE RW version from CSE RW partition. BUG=b:327842062 TEST=CSE RW update successful on Karis with this patch using below recipe: 1. Overriding the CONFIG_SOC_INTEL_CSE_RW_VERSION="18.0.5.2269" 2. Without overriding the CONFIG_SOC_INTEL_CSE_RW_VERSION="" Platform prior to Intel Meteor Lake would be using #1 and platform starting with Meteor Lake expected to use #2 recipe. Change-Id: I1327c813b7aef77c65766eb9c40003bb8a71d4b6 Signed-off-by: Subrata Banik <subratabanik@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/83831 Reviewed-by: Eric Lai <ericllai@google.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Dinesh Gehlot <digehlot@google.com>
-rw-r--r--src/soc/intel/common/block/cse/Makefile.mk5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/soc/intel/common/block/cse/Makefile.mk b/src/soc/intel/common/block/cse/Makefile.mk
index d41d735462..9196cf8031 100644
--- a/src/soc/intel/common/block/cse/Makefile.mk
+++ b/src/soc/intel/common/block/cse/Makefile.mk
@@ -91,6 +91,7 @@ ifeq ($(CONFIG_SOC_INTEL_CSE_LITE_COMPRESS_ME_RW),y)
$(CSE_LITE_ME_RW)-compression := LZMA
endif
+ifeq ($(CONFIG_SOC_INTEL_CSE_RW_VERSION),"")
INPUT_FILE := $(call strip_quotes,$(CONFIG_SOC_INTEL_CSE_RW_FILE))
TEMP_FILE := $(shell mktemp)
OFFSETS := 16 18 20 22 # Offsets for CSE version components
@@ -105,6 +106,10 @@ $(obj)/cse_rw.version:
rm -f $(TEMP_FILE)
$(eval CSE_RW_CBFS_VERSION := $(shell printf "%d.%d.%d.%d" $(CSE_VERSION_MAJOR)$(CSE_VERSION_MINOR)$(CSE_VERSION_HOTFIX)$(CSE_VERSION_BUILD)))
@echo '$(CSE_RW_CBFS_VERSION)' > $@
+else
+$(obj)/cse_rw.version:
+ @echo '$(call strip_quotes,$(CONFIG_SOC_INTEL_CSE_RW_VERSION))' > $@
+endif
CSE_RW_VERSION = $(call strip_quotes,$(CONFIG_SOC_INTEL_CSE_RW_VERSION_CBFS_NAME))
regions-for-file-$(CSE_RW_VERSION) = FW_MAIN_A,FW_MAIN_B