summaryrefslogtreecommitdiffstats
path: root/sys/amd64/acpica
diff options
context:
space:
mode:
authoriwasaki <iwasaki@FreeBSD.org>2001-11-06 15:00:30 +0000
committeriwasaki <iwasaki@FreeBSD.org>2001-11-06 15:00:30 +0000
commit37688d63276146108db05e433930ef7f0d572d34 (patch)
tree048d74e450c6b6eaaa11cab65d2c0a47191e40d2 /sys/amd64/acpica
parente2aa5ac96dede4de34aabb975cab9a6ee618a276 (diff)
downloadFreeBSD-src-37688d63276146108db05e433930ef7f0d572d34.zip
FreeBSD-src-37688d63276146108db05e433930ef7f0d572d34.tar.gz
Add S4BIOS sleep (BIOS hibernation) and DSDT overriding support.
- Add S4BIOS sleep implementation. This will works well if MIB hw.acpi.s4bios is set (and of course BIOS supports it and hibernation is enabled correctly). - Add DSDT overriding support which is submitted by takawata originally. If loader tunable acpi_dsdt_load="YES" and DSDT file is set to acpi_dsdt_name (default DSDT file name is /boot/acpi_dsdt.aml), ACPI CA core loads DSDT from given file rather than BIOS memory block. DSDT file can be generated by iasl in ports/devel/acpicatools/. - Add new files so that we can add our proposed additional code to Intel ACPI CA into these files temporary. They will be removed when similar code is added into ACPI CA officially.
Diffstat (limited to 'sys/amd64/acpica')
-rw-r--r--sys/amd64/acpica/acpi_wakeup.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/sys/amd64/acpica/acpi_wakeup.c b/sys/amd64/acpica/acpi_wakeup.c
index ad67313..3ba70b1 100644
--- a/sys/amd64/acpica/acpi_wakeup.c
+++ b/sys/amd64/acpica/acpi_wakeup.c
@@ -52,6 +52,8 @@
#include "acpi.h"
+#include <dev/acpica/acpica_support.h>
+
#include <dev/acpica/acpivar.h>
#include "acpi_wakecode.h"
@@ -236,7 +238,13 @@ acpi_sleep_machdep(struct acpi_softc *sc, int state)
acpi_printcpu();
}
- if ((status = AcpiEnterSleepState(state)) != AE_OK) {
+ if (state == ACPI_STATE_S4 && sc->acpi_s4bios) {
+ status = AcpiEnterSleepStateS4Bios();
+ } else {
+ status = AcpiEnterSleepState(state);
+ }
+
+ if (status != AE_OK) {
device_printf(sc->acpi_dev,
"AcpiEnterSleepState failed - %s\n",
AcpiFormatException(status));
OpenPOWER on IntegriCloud