coreboot-kgpe-d16/payloads/libpayload/drivers
Julius Werner d67c6876b5 Turn CBMEM console into a ring buffer that can persist across reboots
This patch allows the CBMEM console to persist across reboots, which
should greatly help post factum debugging of issues involving multiple
reboots. In order to prevent the console from filling up, it will
instead operate as a ring buffer that continues to evict the oldest
lines once full. (This means that if even a single boot doesn't fit into
the buffer, we will now drop the oldest lines whereas previous code
would've dropped the newest lines instead.)

The console control structure is modified in a sorta
backwards-compatible way, so that new readers can continue to work with
old console buffers and vice versa. When an old reader reads a new
buffer that has already once overflowed (i.e. is operating in true ring
buffer mode) it will print lines out of order, but it will at least
still print out the whole console content and not do any illegal memory
accesses (assuming it correctly implemented cursor overflow as it was
already possible before this patch).

BUG=chromium:651966
TEST=Rebooted and confirmed output repeatedly on a Kevin and a Falco.
Also confirmed correct behavior across suspend/resume for the latter.

Change-Id: Ifcbf59d58e1ad20995b98d111c4647281fbb45ff
Signed-off-by: Julius Werner <jwerner@chromium.org>
Reviewed-on: https://review.coreboot.org/18301
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
2017-04-20 00:29:07 +02:00
..
serial libpayload/libc/console: Flush input driver buffer on init 2017-04-19 19:19:56 +02:00
storage libpayload: Add Cougar Point PCH's AHCI to whitelist 2016-12-08 01:36:01 +01:00
timer libpayload: timer: cast cpu_khz to make sure 64bit math is used 2017-01-06 18:40:44 +01:00
udc Remove extra newlines from the end of all coreboot files. 2016-07-31 18:19:33 +02:00
usb libpayload: usbhub: Force enumeration of all connected ports on init 2017-03-15 00:54:23 +01:00
video libpayload: cbgfx: Show square images on portrait displays 2017-04-17 18:12:02 +02:00
Makefile.inc libpayload: Replace majority of timer drivers with a generic one 2016-10-17 22:43:37 +02:00
cbmem_console.c Turn CBMEM console into a ring buffer that can persist across reboots 2017-04-20 00:29:07 +02:00
hid.c Remove empty lines at end of file 2015-06-08 00:55:07 +02:00
keyboard.c libpayload/libc/console: Flush input driver buffer on init 2017-04-19 19:19:56 +02:00
nvram.c libpayload: Make Kconfig bools use IS_ENABLED() 2015-06-30 18:55:15 +02:00
options.c libpayload/options: Fix out of array read. 2014-01-19 11:51:23 +01:00
pci.c Remove empty lines at end of file 2015-06-08 00:55:07 +02:00
speaker.c Fix libpayload speaker driver 2011-10-27 10:49:41 +02:00