From 101ef0b528461a3fb662db150b16607430a2bd94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ky=C3=B6sti=20M=C3=A4lkki?= Date: Sun, 18 Aug 2019 06:58:42 +0300 Subject: lib/bootblock: Add simplified entry with basetime MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This allows for minor optimization as num_timestamps becomes a constant zero for a function with local scope. The loop with calls to timestamp_add() gets removed from bootblock. Change-Id: Id230075c0e76fe377b6ea8c8ddf8318e07d29b91 Signed-off-by: Kyösti Mälkki Reviewed-on: https://review.coreboot.org/c/coreboot/+/34972 Tested-by: build bot (Jenkins) Reviewed-by: Julius Werner --- src/soc/amd/stoneyridge/bootblock/bootblock.c | 2 +- src/soc/intel/apollolake/bootblock/bootblock.c | 2 +- src/soc/intel/braswell/bootblock/bootblock.c | 2 +- src/soc/intel/cannonlake/bootblock/bootblock.c | 2 +- src/soc/intel/denverton_ns/bootblock/bootblock.c | 2 +- src/soc/intel/icelake/bootblock/bootblock.c | 2 +- src/soc/intel/quark/bootblock/bootblock.c | 2 +- src/soc/intel/skylake/bootblock/bootblock.c | 2 +- 8 files changed, 8 insertions(+), 8 deletions(-) (limited to 'src/soc') diff --git a/src/soc/amd/stoneyridge/bootblock/bootblock.c b/src/soc/amd/stoneyridge/bootblock/bootblock.c index 9239030d6c..a079ec2561 100644 --- a/src/soc/amd/stoneyridge/bootblock/bootblock.c +++ b/src/soc/amd/stoneyridge/bootblock/bootblock.c @@ -88,7 +88,7 @@ asmlinkage void bootblock_c_entry(uint64_t base_timestamp) } /* TSC cannot be relied upon. Override the TSC value passed in. */ - bootblock_main_with_timestamp(timestamp_get(), NULL, 0); + bootblock_main_with_basetime(timestamp_get()); } void bootblock_soc_early_init(void) diff --git a/src/soc/intel/apollolake/bootblock/bootblock.c b/src/soc/intel/apollolake/bootblock/bootblock.c index f86c18ed43..a07c4620af 100644 --- a/src/soc/intel/apollolake/bootblock/bootblock.c +++ b/src/soc/intel/apollolake/bootblock/bootblock.c @@ -69,7 +69,7 @@ asmlinkage void bootblock_c_entry(uint64_t base_timestamp) enable_rtc_upper_bank(); /* Call lib/bootblock.c main */ - bootblock_main_with_timestamp(base_timestamp, NULL, 0); + bootblock_main_with_basetime(base_timestamp); } static void enable_pmcbar(void) diff --git a/src/soc/intel/braswell/bootblock/bootblock.c b/src/soc/intel/braswell/bootblock/bootblock.c index 2d1a3e8687..d8d953c8a7 100644 --- a/src/soc/intel/braswell/bootblock/bootblock.c +++ b/src/soc/intel/braswell/bootblock/bootblock.c @@ -31,7 +31,7 @@ asmlinkage void bootblock_c_entry(uint64_t base_timestamp) { /* Call lib/bootblock.c main */ - bootblock_main_with_timestamp(base_timestamp, NULL, 0); + bootblock_main_with_basetime(base_timestamp); } static void program_base_addresses(void) diff --git a/src/soc/intel/cannonlake/bootblock/bootblock.c b/src/soc/intel/cannonlake/bootblock/bootblock.c index 30c2266096..653ba30563 100644 --- a/src/soc/intel/cannonlake/bootblock/bootblock.c +++ b/src/soc/intel/cannonlake/bootblock/bootblock.c @@ -44,7 +44,7 @@ const FSPT_UPD temp_ram_init_params = { asmlinkage void bootblock_c_entry(uint64_t base_timestamp) { /* Call lib/bootblock.c main */ - bootblock_main_with_timestamp(base_timestamp, NULL, 0); + bootblock_main_with_basetime(base_timestamp); } void bootblock_soc_early_init(void) diff --git a/src/soc/intel/denverton_ns/bootblock/bootblock.c b/src/soc/intel/denverton_ns/bootblock/bootblock.c index e9800c8ae5..f75de1f2d0 100644 --- a/src/soc/intel/denverton_ns/bootblock/bootblock.c +++ b/src/soc/intel/denverton_ns/bootblock/bootblock.c @@ -51,7 +51,7 @@ const FSPT_UPD temp_ram_init_params = { asmlinkage void bootblock_c_entry(uint64_t base_timestamp) { /* Call lib/bootblock.c main */ - bootblock_main_with_timestamp(base_timestamp, NULL, 0); + bootblock_main_with_basetime(base_timestamp); }; void bootblock_soc_early_init(void) diff --git a/src/soc/intel/icelake/bootblock/bootblock.c b/src/soc/intel/icelake/bootblock/bootblock.c index b76dc4ba37..db43e50ec8 100644 --- a/src/soc/intel/icelake/bootblock/bootblock.c +++ b/src/soc/intel/icelake/bootblock/bootblock.c @@ -23,7 +23,7 @@ asmlinkage void bootblock_c_entry(uint64_t base_timestamp) { /* Call lib/bootblock.c main */ - bootblock_main_with_timestamp(base_timestamp, NULL, 0); + bootblock_main_with_basetime(base_timestamp); } void bootblock_soc_early_init(void) diff --git a/src/soc/intel/quark/bootblock/bootblock.c b/src/soc/intel/quark/bootblock/bootblock.c index ff5b9b2a52..2b2fc29f59 100644 --- a/src/soc/intel/quark/bootblock/bootblock.c +++ b/src/soc/intel/quark/bootblock/bootblock.c @@ -82,7 +82,7 @@ asmlinkage void bootblock_c_entry(uint64_t base_timestamp) if (CONFIG(ENABLE_DEBUG_LED_BOOTBLOCK_ENTRY)) light_sd_led(); - bootblock_main_with_timestamp(base_timestamp, NULL, 0); + bootblock_main_with_basetime(base_timestamp); } void bootblock_soc_early_init(void) diff --git a/src/soc/intel/skylake/bootblock/bootblock.c b/src/soc/intel/skylake/bootblock/bootblock.c index 4358fba40f..e9ca2d8af2 100644 --- a/src/soc/intel/skylake/bootblock/bootblock.c +++ b/src/soc/intel/skylake/bootblock/bootblock.c @@ -22,7 +22,7 @@ asmlinkage void bootblock_c_entry(uint64_t base_timestamp) { /* Call lib/bootblock.c main */ - bootblock_main_with_timestamp(base_timestamp, NULL, 0); + bootblock_main_with_basetime(base_timestamp); } void bootblock_soc_early_init(void) -- cgit v1.2.3