diff options
Diffstat (limited to 'source/components/hardware/hwsleep.c')
-rw-r--r-- | source/components/hardware/hwsleep.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/source/components/hardware/hwsleep.c b/source/components/hardware/hwsleep.c index d85d04785..2b857d970 100644 --- a/source/components/hardware/hwsleep.c +++ b/source/components/hardware/hwsleep.c @@ -339,7 +339,7 @@ ACPI_STATUS AcpiHwLegacyWakePrep ( UINT8 SleepState) { - ACPI_STATUS Status; + ACPI_STATUS Status = AE_OK; ACPI_BIT_REGISTER_INFO *SleepTypeRegInfo; ACPI_BIT_REGISTER_INFO *SleepEnableRegInfo; UINT32 Pm1aControl; @@ -353,9 +353,7 @@ AcpiHwLegacyWakePrep ( * This is unclear from the ACPI Spec, but it is required * by some machines. */ - Status = AcpiGetSleepTypeData (ACPI_STATE_S0, - &AcpiGbl_SleepTypeA, &AcpiGbl_SleepTypeB); - if (ACPI_SUCCESS (Status)) + if (AcpiGbl_SleepTypeAS0 != ACPI_SLEEP_TYPE_INVALID) { SleepTypeRegInfo = AcpiHwGetBitRegisterInfo (ACPI_BITREG_SLEEP_TYPE); @@ -376,9 +374,9 @@ AcpiHwLegacyWakePrep ( /* Insert the SLP_TYP bits */ - Pm1aControl |= (AcpiGbl_SleepTypeA << + Pm1aControl |= (AcpiGbl_SleepTypeAS0 << SleepTypeRegInfo->BitPosition); - Pm1bControl |= (AcpiGbl_SleepTypeB << + Pm1aControl |= (AcpiGbl_SleepTypeBS0 << SleepTypeRegInfo->BitPosition); /* Write the control registers and ignore any errors */ |