From 4a4abaf25f6db9d87b65de7f4c5d9ba170f22d44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Axel=20D=C3=B6rfler?= Date: Sun, 12 Oct 2008 19:59:51 +0000 Subject: [PATCH] mmlr: * Actually call prepare_sleep_state() instead of calling enter_sleep_state() twice... * Commented out disabling interrupts when calling enter_sleep_state(), as our ACPI modules would then crash (needs memory & uses sems with interrupts disabled). This way, it at least works on some hardware, including emulators (as before). git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@28004 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/system/kernel/arch/x86/arch_cpu.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/system/kernel/arch/x86/arch_cpu.cpp b/src/system/kernel/arch/x86/arch_cpu.cpp index 0f251748f9..0a83938304 100644 --- a/src/system/kernel/arch/x86/arch_cpu.cpp +++ b/src/system/kernel/arch/x86/arch_cpu.cpp @@ -108,11 +108,11 @@ acpi_shutdown(void) if (get_module(B_ACPI_MODULE_NAME, (module_info**)&acpi) != B_OK) return B_NOT_SUPPORTED; - status_t status = acpi->enter_sleep_state(ACPI_POWER_STATE_OFF); + status_t status = acpi->prepare_sleep_state(ACPI_POWER_STATE_OFF, NULL, 0); if (status == B_OK) { - cpu_status state = disable_interrupts(); + //cpu_status state = disable_interrupts(); status = acpi->enter_sleep_state(ACPI_POWER_STATE_OFF); - restore_interrupts(state); + //restore_interrupts(state); } put_module(B_ACPI_MODULE_NAME);