1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-28 16:43:09 +00:00

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:
Mitsuru IWASAKI 2001-11-11 15:36:35 +00:00
parent 94eacee1fc
commit 8d2d52e43a
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=86261

View File

@ -237,6 +237,7 @@ AcpiEnterSleepState (
UINT8 TypeB;
UINT16 PM1AControl;
UINT16 PM1BControl;
UINT32 Retry;
FUNCTION_TRACE ("AcpiEnterSleepState");
@ -318,9 +319,16 @@ AcpiEnterSleepState (
/* wait until we enter sleep state */
Retry = 1000;
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));