[coreboot-gerrit] New patch to review for coreboot: memlayout: Add TIMESTAMP region

Marc Jones (marc.jones@se-eng.com) gerrit at coreboot.org
Wed Jul 1 00:16:32 CEST 2015


Marc Jones (marc.jones at se-eng.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/10734

-gerrit

commit d1971748f29739cc3cfd840306754c596b2b4cc6
Author: Furquan Shaikh <furquan at google.com>
Date:   Tue Oct 14 15:26:47 2014 -0700

    memlayout: Add TIMESTAMP region
    
    This region is used to store the timestamps from bootblock and verstage when
    cbmem is not yet initialized. Once cbmem is setup, the timestamps from this
    region can be retrieved and filled up properly in cbmem. In order to achieve
    this a new Kconfig option is introduced HAS_TIMESTAMP_REGION. This is to
    maintain compatbility with older boards which do not use this region.
    
    BUG=chrome-os-partner:32973
    BRANCH=None
    TEST=cbmem -t and verified timestamps on ryu
    
    Change-Id: I4d78653c0595523eeeb02115423e7fecceea5e1e
    Signed-off-by: Furquan Shaikh <furquan at google.com>
    Reviewed-on: https://chromium-review.googlesource.com/223348
    Reviewed-by: Aaron Durbin <adurbin at chromium.org>
    Reviewed-by: Patrick Georgi <pgeorgi at chromium.org>
    Tested-by: Furquan Shaikh <furquan at chromium.org>
    Commit-Queue: Furquan Shaikh <furquan at chromium.org>
    (cherry picked from commit 3f77e81a369d032cbb0bc072872b373533b000e9)
    Signed-off-by: Marc Jones <marc.jones at se-eng.com>
---
 src/Kconfig             | 8 ++++++++
 src/include/memlayout.h | 3 +++
 src/include/symbols.h   | 4 ++++
 3 files changed, 15 insertions(+)

diff --git a/src/Kconfig b/src/Kconfig
index 94b3508..814fd23 100644
--- a/src/Kconfig
+++ b/src/Kconfig
@@ -200,6 +200,14 @@ config COLLECT_TIMESTAMPS
 	  Make coreboot create a table of timer-ID/timer-value pairs to
 	  allow measuring time spent at different phases of the boot process.
 
+config HAS_PRECBMEM_TIMESTAMP_REGION
+	bool "Timestamp region exists for pre-cbmem timestamps"
+	depends on COLLECT_TIMESTAMPS
+	help
+	  A separate region is maintained to allow storing of timestamps before
+	  cbmem comes up. This is useful for storing timestamps across different
+	  stage boundaries.
+
 config USE_BLOBS
 	bool "Allow use of binary-only repository"
 	default n
diff --git a/src/include/memlayout.h b/src/include/memlayout.h
index 2771f2f..a529628 100644
--- a/src/include/memlayout.h
+++ b/src/include/memlayout.h
@@ -47,6 +47,9 @@
 
 #define DRAM_START(addr) SYMBOL(dram, addr)
 
+#define TIMESTAMP(addr, size) \
+	REGION(timestamp, addr, size, 8)
+
 #define PRERAM_CBMEM_CONSOLE(addr, size) \
 	REGION(preram_cbmem_console, addr, size, 4)
 
diff --git a/src/include/symbols.h b/src/include/symbols.h
index 9102e82..3fbf819 100644
--- a/src/include/symbols.h
+++ b/src/include/symbols.h
@@ -28,6 +28,10 @@ extern u8 _esram[];
 
 extern u8 _dram[];
 
+extern u8 _timestamp[];
+extern u8 _etimestamp[];
+#define _timestamp_size	(_etimestamp - _timestamp)
+
 extern u8 _preram_cbmem_console[];
 extern u8 _epreram_cbmem_console[];
 #define _preram_cbmem_console_size \



More information about the coreboot-gerrit mailing list