aboutsummaryrefslogtreecommitdiff
path: root/src/drivers/intel/fsp2_0/Makefile.inc
diff options
context:
space:
mode:
authorAaron Durbin <adurbin@chromium.org>2020-05-15 15:09:10 -0600
committerAaron Durbin <adurbin@chromium.org>2020-05-28 19:37:18 +0000
commita85febcb1cfd31bd4d27e955fc2bcf9f8ef16cd5 (patch)
treed6e2d2dfb841b696b8df807c3ecf78b6698724d7 /src/drivers/intel/fsp2_0/Makefile.inc
parent84f394e9c0cd9a82948f0027a76c8b41b14a11bc (diff)
drivers/intel/fsp2_0: add option to compress FSP-S in cbfs
Allow the ability for chipset or mainboard to choose to compress FSP-S in cbfs using LZMA or LZ4 routines. To accomplish this fsp_load_component() is added as an assist for performing the necessary logic and allow the caller to provide the destination selection. Since the main cbfs decompression paths are utilized add the appropriate checks for including compression algorithms under the FSP-S compression options. On picasso FSP-S (debug builds) the following savings were measured: no-compression: fsps.bin 327680 none FSP_COMPRESS_FSP_S_LZ4: fsps.bin 98339 LZ4 (327680 decompressed) -70% FSP_COMPRESS_FSP_S_LZMA: fsps.bin 71275 LZMA (327680 decompressed) -78% BUG=b:155322763,b:150746858,b:152909132 Change-Id: I8aa5d8c1cbaf4d08f38a918a9031a2570bc5247e Signed-off-by: Aaron Durbin <adurbin@chromium.org> Reviewed-on: https://review.coreboot.org/c/coreboot/+/41449 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Furquan Shaikh <furquan@google.com>
Diffstat (limited to 'src/drivers/intel/fsp2_0/Makefile.inc')
-rw-r--r--src/drivers/intel/fsp2_0/Makefile.inc6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/drivers/intel/fsp2_0/Makefile.inc b/src/drivers/intel/fsp2_0/Makefile.inc
index a46f9b88a2..6c82b28d21 100644
--- a/src/drivers/intel/fsp2_0/Makefile.inc
+++ b/src/drivers/intel/fsp2_0/Makefile.inc
@@ -56,6 +56,12 @@ endif
cbfs-files-$(CONFIG_ADD_FSP_BINARIES) += $(FSP_S_CBFS)
$(FSP_S_CBFS)-file := $(call strip_quotes,$(CONFIG_FSP_S_FILE))
$(FSP_S_CBFS)-type := fsp
+ifeq ($(CONFIG_FSP_COMPRESS_FSP_S_LZMA),y)
+$(FSP_S_CBFS)-compression := LZMA
+endif
+ifeq ($(CONFIG_FSP_COMPRESS_FSP_S_LZ4),y)
+$(FSP_S_CBFS)-compression := LZ4
+endif
ifeq ($(CONFIG_FSP_USE_REPO),y)
$(obj)/Fsp_M.fd: $(call strip_quotes,$(CONFIG_FSP_FD_PATH))