summaryrefslogtreecommitdiff
path: root/src/soc/intel
diff options
context:
space:
mode:
Diffstat (limited to 'src/soc/intel')
-rw-r--r--src/soc/intel/baytrail/romstage/romstage.c7
-rw-r--r--src/soc/intel/broadwell/romstage/romstage.c9
-rw-r--r--src/soc/intel/fsp_baytrail/romstage/romstage.c7
3 files changed, 3 insertions, 20 deletions
diff --git a/src/soc/intel/baytrail/romstage/romstage.c b/src/soc/intel/baytrail/romstage/romstage.c
index a61b571ecc..124eb6ea5f 100644
--- a/src/soc/intel/baytrail/romstage/romstage.c
+++ b/src/soc/intel/baytrail/romstage/romstage.c
@@ -210,7 +210,6 @@ static int chipset_prev_sleep_state(struct chipset_power_state *ps)
/* Entry from the mainboard. */
void romstage_common(struct romstage_params *params)
{
- struct romstage_handoff *handoff;
struct chipset_power_state *ps;
int prev_sleep_state;
@@ -232,11 +231,7 @@ void romstage_common(struct romstage_params *params)
timestamp_add_now(TS_AFTER_INITRAM);
- handoff = romstage_handoff_find_or_add();
- if (handoff != NULL)
- handoff->s3_resume = (prev_sleep_state == ACPI_S3);
- else
- printk(BIOS_DEBUG, "Romstage handoff structure not added!\n");
+ romstage_handoff_init(prev_sleep_state == ACPI_S3);
if (IS_ENABLED(CONFIG_LPC_TPM)) {
init_tpm(prev_sleep_state == ACPI_S3);
diff --git a/src/soc/intel/broadwell/romstage/romstage.c b/src/soc/intel/broadwell/romstage/romstage.c
index 44df88cab2..849c55d3e8 100644
--- a/src/soc/intel/broadwell/romstage/romstage.c
+++ b/src/soc/intel/broadwell/romstage/romstage.c
@@ -89,8 +89,6 @@ void * asmlinkage romstage_main(unsigned long bist,
/* Entry from the mainboard. */
void romstage_common(struct romstage_params *params)
{
- struct romstage_handoff *handoff;
-
post_code(0x32);
timestamp_add_now(TS_BEFORE_INITRAM);
@@ -114,12 +112,7 @@ void romstage_common(struct romstage_params *params)
timestamp_add_now(TS_AFTER_INITRAM);
- handoff = romstage_handoff_find_or_add();
- if (handoff != NULL)
- handoff->s3_resume = (params->power_state->prev_sleep_state ==
- ACPI_S3);
- else
- printk(BIOS_DEBUG, "Romstage handoff structure not added!\n");
+ romstage_handoff_init(params->power_state->prev_sleep_state == ACPI_S3);
#if CONFIG_LPC_TPM
init_tpm(params->power_state->prev_sleep_state == ACPI_S3);
diff --git a/src/soc/intel/fsp_baytrail/romstage/romstage.c b/src/soc/intel/fsp_baytrail/romstage/romstage.c
index a7ed414da8..9d204d16e2 100644
--- a/src/soc/intel/fsp_baytrail/romstage/romstage.c
+++ b/src/soc/intel/fsp_baytrail/romstage/romstage.c
@@ -218,7 +218,6 @@ void romstage_main_continue(EFI_STATUS status, void *hob_list_ptr)
int cbmem_was_initted;
void *cbmem_hob_ptr;
uint32_t prev_sleep_state;
- struct romstage_handoff *handoff;
timestamp_add_now(TS_AFTER_INITRAM);
@@ -257,11 +256,7 @@ void romstage_main_continue(EFI_STATUS status, void *hob_list_ptr)
*(u32*)cbmem_hob_ptr = (u32)hob_list_ptr;
post_code(0x4e);
- handoff = romstage_handoff_find_or_add();
- if (handoff != NULL)
- handoff->s3_resume = (prev_sleep_state == ACPI_S3);
- else
- printk(BIOS_DEBUG, "Romstage handoff structure not added!\n");
+ romstage_handoff_init(prev_sleep_state == ACPI_S3);
post_code(0x4f);