From 4221a195745837b05725d7ffeda415516ac44a7f Mon Sep 17 00:00:00 2001 From: Stefan Reinauer Date: Mon, 15 Oct 2012 15:23:20 -0700 Subject: Add method for delaying adding of timestamps In hardwaremain() we can't add timestamps before we actually reinitialized the cbmem area. Hence we kept the timestamps in an array and added them later. This is ugly and intrusive and helped hiding a bug that prevented any timestamps to be logged in hardwaremain() when coming out of an S3 resume. The problem is solved by moving the logic to keep a few timestamps around into the timestamp code. This also gets rid of a lot of ugly ifdefs in hardwaremain.c Change-Id: I945fc4c77e990f620c18cbd054ccd87e746706ef Signed-off-by: Stefan Reinauer Reviewed-on: http://review.coreboot.org/1785 Tested-by: build bot (Jenkins) Reviewed-by: Ronald G. Minnich --- src/include/timestamp.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/include') diff --git a/src/include/timestamp.h b/src/include/timestamp.h index 8bf5287c69..e76716c608 100644 --- a/src/include/timestamp.h +++ b/src/include/timestamp.h @@ -57,10 +57,14 @@ enum timestamp_id { void timestamp_init(tsc_t base); void timestamp_add(enum timestamp_id id, tsc_t ts_time); void timestamp_add_now(enum timestamp_id id); +void timestamp_stash(enum timestamp_id id); +void timestamp_sync(void); #else #define timestamp_init(base) #define timestamp_add(id, time) #define timestamp_add_now(id) +#define timestamp_stash(id) +#define timestamp_sync() #endif #endif -- cgit v1.2.3