[coreboot-gerrit] New patch to review for coreboot: dcf541d rk3288: Disable ramstage compression by default

Patrick Georgi (pgeorgi@google.com) gerrit at coreboot.org
Fri Apr 17 15:29:52 CEST 2015


Patrick Georgi (pgeorgi at google.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/9792

-gerrit

commit dcf541de52f119b9ec964d77787c0fb6e14bf641
Author: Julius Werner <jwerner at chromium.org>
Date:   Tue Dec 9 12:18:00 2014 -0800

    rk3288: Disable ramstage compression by default
    
    The ramstage is loaded from romstage, so the LZMA scratchpad buffer used
    to decompress it is part of the romstage BSS in SRAM. On RK3288, SRAM
    cannot be cached which makes the decompression so slow that it's faster
    to just load an uncompressed image from SPI. Disable ramstage
    compression on this SoC to account for that.
    
    [pg: implementation avoids restructuring all of Kconfig]
    
    BRANCH=None
    BUG=None
    TEST=Built for Pinky and Falco, confirmed that the former didn't have
    COMPRESS_RAMSTAGE in its .config and the latter still did. Measured a
    speed-up of about 35ms on Pinky. (For some weird reason, the
    decompression of the payload also takes way longer than on other
    platforms, although not as long as the ramstage. I have no explanation
    for that and can't really think of a good way to figure it out... maybe
    the Cortex-A12 is just terrible at some operation that LZMA uses a lot?)
    
    Change-Id: I9f67f7537696ec09496483b16b59a8b73f4cb11b
    Signed-off-by: Julius Werner <jwerner at chromium.org>
    Reviewed-on: https://chromium-review.googlesource.com/234192
    Reviewed-by: Aaron Durbin <adurbin at chromium.org>
    Signed-off-by: Patrick Georgi <pgeorgi at chromium.org>
---
 src/Kconfig                     | 7 ++++++-
 src/soc/rockchip/rk3288/Kconfig | 1 +
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/Kconfig b/src/Kconfig
index a6032c7..2663f50 100644
--- a/src/Kconfig
+++ b/src/Kconfig
@@ -135,9 +135,14 @@ config STATIC_OPTION_TABLE
 	  every boot.  Use this if you want the NVRAM configuration to
 	  never be modified from its default values.
 
+config UNCOMPRESSED_RAMSTAGE
+	bool
+	default n
+
 config COMPRESS_RAMSTAGE
 	bool "Compress ramstage with LZMA"
-	default y
+	default y if !UNCOMPRESSED_RAMSTAGE
+	default n
 	help
 	  Compress ramstage to save memory in the flash image. Note
 	  that decompression might slow down booting if the boot flash
diff --git a/src/soc/rockchip/rk3288/Kconfig b/src/soc/rockchip/rk3288/Kconfig
index 48ea7fc..60d69f6 100644
--- a/src/soc/rockchip/rk3288/Kconfig
+++ b/src/soc/rockchip/rk3288/Kconfig
@@ -30,6 +30,7 @@ config SOC_ROCKCHIP_RK3288
 	select HAVE_UART_MEMORY_MAPPED
 	select HAVE_UART_SPECIAL
 	select BOOTBLOCK_CONSOLE
+	select UNCOMPRESSED_RAMSTAGE
 
 if SOC_ROCKCHIP_RK3288
 



More information about the coreboot-gerrit mailing list