From a7d924412a4300e91b3bd6eb3581b954b02f8d37 Mon Sep 17 00:00:00 2001 From: Julius Werner Date: Tue, 2 Dec 2014 20:51:19 -0800 Subject: timestamps: You can never have enough of them! Now that we have timestamps in pre-RAM stages, let's actually make use of them. This patch adds several timestamps to both the bootblock and especially the verstage to allow more fine-grained boot time tracking. Some of the introduced timestamps can appear more than once per boot. This doesn't seem to be a problem for both coreboot and the cbmem utility, and the context makes it clear which operation was timestamped at what point. Also simplifies cbmem's timestamp printing routine a bit, fixing a display bug when a timestamp had a section of exactly ",000," in it (e.g. 1,000,185). BRANCH=None BUG=None TEST=Booted Pinky, Blaze and Falco, confirmed that all timestamps show up and contained sane values. Booted Storm (no timestamps here since it doesn't support pre-RAM timestamps yet). Change-Id: I7f4d6aba3ebe3db0d003c7bcb2954431b74961b3 Signed-off-by: Patrick Georgi Original-Commit-Id: 7a2ce81722aba85beefcc6c81f9908422b8da8fa Original-Change-Id: I5979bfa9445a9e0aba98ffdf8006c21096743456 Original-Signed-off-by: Julius Werner Original-Reviewed-on: https://chromium-review.googlesource.com/234063 Original-Reviewed-by: Aaron Durbin Reviewed-on: http://review.coreboot.org/9608 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer --- src/include/timestamp.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'src/include') diff --git a/src/include/timestamp.h b/src/include/timestamp.h index c2bc6f148f..cd648ea00b 100644 --- a/src/include/timestamp.h +++ b/src/include/timestamp.h @@ -46,6 +46,10 @@ enum timestamp_id { TS_START_RAMSTAGE = 10, TS_START_BOOTBLOCK = 11, TS_END_BOOTBLOCK = 12, + TS_START_COPYROM = 13, + TS_END_COPYROM = 14, + TS_START_ULZMA = 15, + TS_END_ULZMA = 16, TS_DEVICE_ENUMERATE = 30, TS_FSP_BEFORE_ENUMERATE, TS_FSP_AFTER_ENUMERATE, @@ -60,6 +64,20 @@ enum timestamp_id { TS_LOAD_PAYLOAD = 90, TS_ACPI_WAKE_JUMP = 98, TS_SELFBOOT_JUMP = 99, + + /* 500+ reserved for vendorcode extensions (500-600: google/chromeos) */ + TS_START_COPYVER = 501, + TS_END_COPYVER = 502, + TS_START_TPMINIT = 503, + TS_END_TPMINIT = 504, + TS_START_VERIFY_SLOT = 505, + TS_END_VERIFY_SLOT = 506, + TS_START_HASH_BODY = 507, + TS_DONE_LOADING = 508, + TS_DONE_HASHING = 509, + TS_END_HASH_BODY = 510, + + /* 1000+ reserved for payloads (1000-1200: ChromeOS depthcharge) */ }; #if CONFIG_COLLECT_TIMESTAMPS && (CONFIG_EARLY_CBMEM_INIT || !defined(__PRE_RAM__)) -- cgit v1.2.3