diff options
Diffstat (limited to 'src/mainboard/kontron/ktqm77')
-rw-r--r-- | src/mainboard/kontron/ktqm77/romstage.c | 26 |
1 files changed, 5 insertions, 21 deletions
diff --git a/src/mainboard/kontron/ktqm77/romstage.c b/src/mainboard/kontron/ktqm77/romstage.c index f78e293b81..22fff4201b 100644 --- a/src/mainboard/kontron/ktqm77/romstage.c +++ b/src/mainboard/kontron/ktqm77/romstage.c @@ -156,12 +156,6 @@ void main(unsigned long bist) u32 pm1_cnt; u16 pm1_sts; -#if CONFIG_COLLECT_TIMESTAMPS - tsc_t start_romstage_time; - tsc_t before_dram_time; - tsc_t after_dram_time; - tsc_t base_time = get_initial_timestamp(); -#endif struct pei_data pei_data = { pei_version: PEI_VERSION, mchbar: DEFAULT_MCHBAR, @@ -216,9 +210,8 @@ void main(unsigned long bist) pcie_init: 1, }; -#if CONFIG_COLLECT_TIMESTAMPS - start_romstage_time = rdtsc(); -#endif + timestamp_init(get_initial_timestamp()); + timestamp_add_now(TS_START_ROMSTAGE); if (bist == 0) enable_lapic(); @@ -289,14 +282,10 @@ void main(unsigned long bist) post_code(0x3a); pei_data.boot_mode = boot_mode; -#if CONFIG_COLLECT_TIMESTAMPS - before_dram_time = rdtsc(); -#endif + timestamp_add_now(TS_BEFORE_INITRAM); sdram_initialize(&pei_data); -#if CONFIG_COLLECT_TIMESTAMPS - after_dram_time = rdtsc(); -#endif + timestamp_add_now(TS_AFTER_INITRAM); post_code(0x3c); rcba_config(); @@ -333,13 +322,8 @@ void main(unsigned long bist) } #endif post_code(0x3f); -#if CONFIG_COLLECT_TIMESTAMPS - timestamp_init(base_time); - timestamp_add(TS_START_ROMSTAGE, start_romstage_time ); - timestamp_add(TS_BEFORE_INITRAM, before_dram_time ); - timestamp_add(TS_AFTER_INITRAM, after_dram_time ); + timestamp_sync(); timestamp_add_now(TS_END_ROMSTAGE); -#endif #if CONFIG_CONSOLE_CBMEM /* Keep this the last thing this function does. */ cbmemc_reinit(); |