From 7d2b81c18d891a11420088c37cb17bb1c8d73ba9 Mon Sep 17 00:00:00 2001 From: Duncan Laurie Date: Sat, 23 Jun 2012 16:08:47 -0700 Subject: ELOG: Add support for flash based event log This is based around the SMBIOS event log specification but expanded with OEM event types to support more specific and relevant system events. It requires flash storage and a minimum 4K block (or flash block size) that should be allocated in the FMAP. A copy of the event log is maintained in memory for convenience and speed and the in-memory copy is written to flash at specific points. The log is automatically shunk when it reaches a configurable full threshold in order to not get stuck with a full log that needs OS help to clear. ELOG implements the specification published here: http://code.google.com/p/firmware-event-log/wiki/FirmwareEventLogDesign And is similar to what we use in other firmware at Google. This implementation does not support double-buffered flash regions. This is done because speed is valued over the log reliability and it keeps the code simpler for the first version. This is a large commit and by itself it just provides a new driver that is made available to coreboot. Without additional patches it is not very useful, but the end result is an event log that will contain entries like this: 171 | 2012-06-23 16:02:55 | System boot | 285 172 | 2012-06-23 16:02:55 | EC Event | Power Button 173 | 2012-06-23 16:02:55 | SUS Power Fail 174 | 2012-06-23 16:02:55 | System Reset 175 | 2012-06-23 16:02:55 | ACPI Wake | S5 Change-Id: I985524c67f525c8a268eccbd856c1a4c2a426889 Signed-off-by: Duncan Laurie Reviewed-on: http://review.coreboot.org/1311 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich --- src/drivers/elog/Makefile.inc | 1 + 1 file changed, 1 insertion(+) create mode 100644 src/drivers/elog/Makefile.inc (limited to 'src/drivers/elog/Makefile.inc') diff --git a/src/drivers/elog/Makefile.inc b/src/drivers/elog/Makefile.inc new file mode 100644 index 0000000000..a01841db96 --- /dev/null +++ b/src/drivers/elog/Makefile.inc @@ -0,0 +1 @@ +ramstage-$(CONFIG_ELOG) += elog.c -- cgit v1.2.3