summaryrefslogtreecommitdiffstats
path: root/sys/amd64/acpica
diff options
context:
space:
mode:
authoriwasaki <iwasaki@FreeBSD.org>2001-07-22 19:13:54 +0000
committeriwasaki <iwasaki@FreeBSD.org>2001-07-22 19:13:54 +0000
commit3e49617509e16373184b50aad15ec9b66b31cca1 (patch)
tree01544b1cf32da46bdc3bc6355f76adadf6800ab7 /sys/amd64/acpica
parent6e2ef43eedee8839bc7db512e0692c80a73cb935 (diff)
downloadFreeBSD-src-3e49617509e16373184b50aad15ec9b66b31cca1.zip
FreeBSD-src-3e49617509e16373184b50aad15ec9b66b31cca1.tar.gz
Don't do sleep state transition if specified sleep state is not
supported by the system.
Diffstat (limited to 'sys/amd64/acpica')
-rw-r--r--sys/amd64/acpica/acpi_wakeup.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/sys/amd64/acpica/acpi_wakeup.c b/sys/amd64/acpica/acpi_wakeup.c
index bd97f77..ad67313 100644
--- a/sys/amd64/acpica/acpi_wakeup.c
+++ b/sys/amd64/acpica/acpi_wakeup.c
@@ -253,13 +253,6 @@ acpi_sleep_machdep(struct acpi_softc *sc, int state)
#endif
icu_reinit();
- pmap_remove(pm, sc->acpi_wakephys,
- sc->acpi_wakephys + PAGE_SIZE);
- if (opage) {
- pmap_enter(pm, sc->acpi_wakephys, page,
- VM_PROT_READ | VM_PROT_WRITE, 0);
- }
-
if (debug_wakeup) {
acpi_savecpu();
acpi_printcpu();
@@ -267,6 +260,12 @@ acpi_sleep_machdep(struct acpi_softc *sc, int state)
}
out:
+ pmap_remove(pm, sc->acpi_wakephys, sc->acpi_wakephys + PAGE_SIZE);
+ if (opage) {
+ pmap_enter(pm, sc->acpi_wakephys, page,
+ VM_PROT_READ | VM_PROT_WRITE, 0);
+ }
+
write_eflags(ef);
return (ret);
OpenPOWER on IntegriCloud