[coreboot-gerrit] New patch to review for coreboot: skylake: fix eventlog on resume path

Patrick Georgi (pgeorgi@google.com) gerrit at coreboot.org
Mon Sep 7 18:42:20 CET 2015


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

-gerrit

commit 272ccdb7ac76329e92c3b71e5666c2b2dfe634c9
Author: Aaron Durbin <adurbin at chromium.org>
Date:   Fri Aug 28 02:14:48 2015 -0500

    skylake: fix eventlog on resume path
    
    The spi_init() routine needs to be called in all boot paths to allow
    writes to the SPI part. The reason is that the write enable is done
    in spi_init(). Moreover, this is also required for a writing a firmware
    update after a resume.
    
    BUG=chrome-os-partner:42115
    BRANCH=None
    TEST=Built and booted glados. Suspended and resumed. Eventlogs show
         up in resume path.
    
    Change-Id: I187baa940bb45ef90ab82e67c02f13d8855d364e
    Signed-off-by: Patrick Georgi <pgeorgi at chromium.org>
    Original-Commit-Id: 8813ab227395cfcba46ad4109730a1eb5897e538
    Original-Change-Id: Ida726fc29e6d49cd9af02c4e57125e09f2599c36
    Original-Signed-off-by: Aaron Durbin <adurbin at chromium.org>
    Original-Reviewed-on: https://chromium-review.googlesource.com/295238
    Original-Reviewed-by: Duncan Laurie <dlaurie at chromium.org>
---
 src/soc/intel/skylake/flash_controller.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/src/soc/intel/skylake/flash_controller.c b/src/soc/intel/skylake/flash_controller.c
index 549e883..a243eb1 100644
--- a/src/soc/intel/skylake/flash_controller.c
+++ b/src/soc/intel/skylake/flash_controller.c
@@ -457,3 +457,15 @@ static struct spi_flash *spi_flash_hwseq_probe(struct spi_slave *spi)
 }
 #endif
 
+#if ENV_RAMSTAGE
+/*
+ * spi_init() needs run unconditionally in every boot (including resume) to
+ * allow write protect to be disabled for eventlog and firmware updates.
+ */
+static void spi_init_cb(void *unused)
+{
+	spi_init();
+}
+
+BOOT_STATE_INIT_ENTRY(BS_DEV_ENABLE, BS_ON_EXIT, spi_init_cb, NULL);
+#endif



More information about the coreboot-gerrit mailing list