Attention is currently required from: Bora Guvendik, Furquan Shaikh, Subrata Banik, Julius Werner, Angel Pons, Aaron Durbin. Bora Guvendik has uploaded a new patch set (#7) to the change originally created by Subrata Banik. ( https://review.coreboot.org/c/coreboot/+/51445 )
Change subject: timestamp: Add new helper functions ......................................................................
timestamp: Add new helper functions
1. timestamp_rewind_base This function will rewind base_time in timestamp table using the delta provided in base_freq_mhz. * 1. Calculate base_delta_tick in ts->tick_freq_mhz using base_delta * ts->tick_freq_mhz / base_freq_mhz. * 2. Update all entries in timestamp table by adding base_delta_tick * 3. Update ts->base_time as ts->base_time - base_delta_tick
2. timestamp_add_relative * This function will add a new entry to timestamp table using the time_from_base expressed in freq_mhz * 1. Calculate time_from_base in ts->tick_freq_mhz using time_from_base * ts->tick_freq_mhz / freq_mhz. * 2. Call timestamp_add_table_entry using ts_table, id, time_from_base_tick
TEST=Rewind the base timestamp, add relative timestamps and verify cbmem -t output
Change-Id: I6b7065ed26e231fc898ae44bcc15cba6fb42b308 Signed-off-by: Subrata Banik subrata.banik@intel.com Signed-off-by: Bora Guvendik bora.guvendik@intel.com --- M src/include/timestamp.h M src/lib/timestamp.c 2 files changed, 78 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/45/51445/7