summaryrefslogtreecommitdiff
path: root/src/drivers/elog/Kconfig
diff options
context:
space:
mode:
authorDuncan Laurie <dlaurie@chromium.org>2012-10-10 14:34:49 -0700
committerRonald G. Minnich <rminnich@gmail.com>2012-11-12 17:09:39 +0100
commit215f27856399b1e4cfe30268fad61bf821af3c19 (patch)
tree9179097ffc1a39aac4d110296e586a83b958ee40 /src/drivers/elog/Kconfig
parent23b0053586974e0db70349a272d8cc09167fb4cb (diff)
downloadcoreboot-215f27856399b1e4cfe30268fad61bf821af3c19.tar.xz
ELOG: Support for non-memory mapped flash
If the event log is stored in flash that is not memory mapped then it must use the SPI controller to read from the flash device instead of relying on memory accesses. In addition a new CBMEM ID is added to keep an resident copy of the ELOG around if needed. The use of CBMEM for this is guarded by a new CONFIG_ELOG_CBMEM config option. This CBMEM buffer is created and filled late in the process when the SMBIOS table is being created because CBMEM is not functional when ELOG is first initialized. The downside to using CBMEM is that events added via the SMI handler at runtime are not reflected in the CBMEM copy because I don't want to let the SMM handler write to memory outside the TSEG region. In reality the only time we add runtime events is at kernel shutdown so the impact is limited. Test: 1) Test with CONFIG_ELOG_CBMEM enabled to ensure the event log is operational and SMBIOS points to address in CBMEM. The test should involve at least on reboot to ensure that the kernel is able to write events as well. > mosys -l smbios info log | grep ^address address | 0xacedd000 > mosys eventlog list 0 | 2012-10-10 14:02:46 | Log area cleared | 4096 1 | 2012-10-10 14:02:46 | System boot | 478 2 | 2012-10-10 14:02:46 | System Reset 3 | 2012-10-10 14:03:33 | Kernel Event | Clean Shutdown 4 | 2012-10-10 14:03:34 | System boot | 479 5 | 2012-10-10 14:03:34 | System Reset 2) Test with CONFIG_ELOG_CBMEM disabled to ensure the event log is operational and SMBIOS points to memory mapped flash. The test should involve at least on reboot to ensure that the kernel is able to write events as well. > mosys -l smbios info log | grep ^address address | 0xffbf0000 > mosys eventlog list 0 | 2012-10-10 14:33:17 | Log area cleared | 4096 1 | 2012-10-10 14:33:18 | System boot | 480 2 | 2012-10-10 14:33:18 | System Reset 3 | 2012-10-10 14:33:35 | Kernel Event | Clean Shutdown 4 | 2012-10-10 14:33:36 | System boot | 481 5 | 2012-10-10 14:33:36 | System Reset Change-Id: I87755d5291ce209c1e647792227c433dc966615d Signed-off-by: Duncan Laurie <dlaurie@chromium.org> Reviewed-on: http://review.coreboot.org/1776 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich <rminnich@gmail.com>
Diffstat (limited to 'src/drivers/elog/Kconfig')
-rw-r--r--src/drivers/elog/Kconfig10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/drivers/elog/Kconfig b/src/drivers/elog/Kconfig
index 7912ab8c79..02274c4a09 100644
--- a/src/drivers/elog/Kconfig
+++ b/src/drivers/elog/Kconfig
@@ -66,6 +66,16 @@ config ELOG_SHRINK_SIZE
Default is 1K.
+config ELOG_CBMEM
+ bool "Store a copy of ELOG in CBMEM"
+ default n
+ help
+ This option will have ELOG store a copy of the flash event log
+ in a CBMEM region and export that address in SMBIOS to the OS.
+ This is useful if the ELOG location is not in memory mapped flash,
+ but it means that events added at runtime via the SMI handler
+ will not be reflected in the CBMEM copy of the log.
+
endif
config ELOG_GSMI