Apply a local change to ACPICA.
Some BIOSes don't set WAK_STS at all, give up waiting for wakeup if we time out.
This commit is contained in:
parent
94eacee1fc
commit
8d2d52e43a
@ -237,6 +237,7 @@ AcpiEnterSleepState (
|
|||||||
UINT8 TypeB;
|
UINT8 TypeB;
|
||||||
UINT16 PM1AControl;
|
UINT16 PM1AControl;
|
||||||
UINT16 PM1BControl;
|
UINT16 PM1BControl;
|
||||||
|
UINT32 Retry;
|
||||||
|
|
||||||
|
|
||||||
FUNCTION_TRACE ("AcpiEnterSleepState");
|
FUNCTION_TRACE ("AcpiEnterSleepState");
|
||||||
@ -318,9 +319,16 @@ AcpiEnterSleepState (
|
|||||||
|
|
||||||
/* wait until we enter sleep state */
|
/* wait until we enter sleep state */
|
||||||
|
|
||||||
|
Retry = 1000;
|
||||||
do
|
do
|
||||||
{
|
{
|
||||||
AcpiOsStall(10000);
|
/*
|
||||||
|
* Some BIOSes don't set WAK_STS at all,
|
||||||
|
* give up waiting for wakeup if we time out.
|
||||||
|
*/
|
||||||
|
if (Retry-- == 0) {
|
||||||
|
break; /* giving up */
|
||||||
|
}
|
||||||
}
|
}
|
||||||
while (!AcpiHwRegisterBitAccess (ACPI_READ, ACPI_MTX_LOCK, WAK_STS));
|
while (!AcpiHwRegisterBitAccess (ACPI_READ, ACPI_MTX_LOCK, WAK_STS));
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user