Remove unnecessary WAK_STS bit waiting code for S1 sleep.
It was duplicated with AcpiEnterSleepState() since acpica-unix-20010816.
This commit is contained in:
parent
305f8307bf
commit
0866b27c11
@ -1279,7 +1279,6 @@ ACPI_STATUS
|
||||
acpi_SetSleepState(struct acpi_softc *sc, int state)
|
||||
{
|
||||
ACPI_STATUS status = AE_OK;
|
||||
UINT16 Count;
|
||||
UINT8 TypeA;
|
||||
UINT8 TypeB;
|
||||
|
||||
@ -1337,19 +1336,6 @@ acpi_SetSleepState(struct acpi_softc *sc, int state)
|
||||
device_printf(sc->acpi_dev, "AcpiEnterSleepState failed - %s\n", AcpiFormatException(status));
|
||||
break;
|
||||
}
|
||||
/* wait for the WAK_STS bit */
|
||||
Count = 0;
|
||||
while (!(AcpiHwRegisterBitAccess(ACPI_READ, ACPI_MTX_LOCK, WAK_STS))) {
|
||||
AcpiOsSleep(0, 1);
|
||||
/*
|
||||
* Some BIOSes don't set WAK_STS at all,
|
||||
* give up waiting for wakeup if we time out.
|
||||
*/
|
||||
if (Count > 1000) {
|
||||
break; /* giving up */
|
||||
}
|
||||
Count++;
|
||||
}
|
||||
}
|
||||
AcpiLeaveSleepState((UINT8)state);
|
||||
DEVICE_RESUME(root_bus);
|
||||
|
Loading…
Reference in New Issue
Block a user