diff --git a/hypervisor/arch/x86/pm.c b/hypervisor/arch/x86/pm.c index 2b3fa7ffd..d86bd9d7f 100644 --- a/hypervisor/arch/x86/pm.c +++ b/hypervisor/arch/x86/pm.c @@ -119,7 +119,8 @@ static uint32_t acpi_gas_read(const struct acpi_generic_address *gas) return ret; } -void do_acpi_s3(struct pm_s_state_data *sstate_data, uint32_t pm1a_cnt_val, uint32_t pm1b_cnt_val) +/* This function supports enter S3 or S5 according to the value given to pm1a_cnt_val and pm1b_cnt_val */ +void do_acpi_sx(struct pm_s_state_data *sstate_data, uint32_t pm1a_cnt_val, uint32_t pm1b_cnt_val) { uint32_t s1, s2; diff --git a/hypervisor/arch/x86/wakeup.S b/hypervisor/arch/x86/wakeup.S index 5cab6fa7f..1af674d1d 100644 --- a/hypervisor/arch/x86/wakeup.S +++ b/hypervisor/arch/x86/wakeup.S @@ -25,7 +25,7 @@ .extern restore_msrs .extern cpu_ctx .extern load_gdtr_and_tr - .extern do_acpi_s3 + .extern do_acpi_sx .global asm_enter_s3 asm_enter_s3: @@ -94,7 +94,7 @@ asm_enter_s3: /*48U=0x30=CPU_CONTEXT_OFFSET_RSI*/ movq 0x30 + cpu_ctx(%rip), %rsi /* pm1a_cnt_val */ - call do_acpi_s3 + call do_acpi_sx /* * When system resume from S3, trampoline_start64 will