Re: Problems with power button after latest acpi_button.c 1.18 change

From: Rudolf Cejka <cejkar_at_fit.vutbr.cz>
Date: Thu, 19 Feb 2004 11:43:48 +0100
Nate Lawson wrote (2004/02/18):
> Please test the following to make sure it fixes your problems with the
> power/sleep buttons.

Hello, I'm sorry, I had to go sleep for some time...

> Index: acpi.c
> diff -u -r1.116 acpi.c
> ...
> Index: acpi_button.c
> diff -u -r1.18 acpi_button.c
> ...

Nate Lawson wrote (2004/02/18):
> I just committed a fix, let me know if it doesn't work for you.

Unfortunately, current revisions src/sys/dev/acpica/acpi.c,v 1.117 and
src/sys/dev/acpica/acpi_button.c,v 1.19 still does not help to me
(and as I saw the others too) and the behavior is still half-functional. 
I have modified my backout-patch to the current revision, which
again returns power button to fully working state (atleast from my
acpi-user's view).

--- sys/dev/acpica/acpi_button.c.orig	Thu Feb 19 06:35:20 2004
+++ sys/dev/acpica/acpi_button.c	Thu Feb 19 11:27:12 2004
_at__at_ -146,16 +146,6 _at__at_
     }
     acpi_device_enable_wake_capability(sc->button_handle, 1);
 
-    /*
-     * If we have fixed buttons defined in the FADT, remove them now that
-     * we have found one in the AML.  Some systems define buttons both ways
-     * but only deliver events to the AML object.
-     */
-    if (event == ACPI_EVENT_POWER_BUTTON && AcpiGbl_FADT->PwrButton == 0)
-	AcpiRemoveFixedEventHandler(event, acpi_event_power_button_sleep);
-    if (event == ACPI_EVENT_SLEEP_BUTTON && AcpiGbl_FADT->SleepButton == 0)
-	AcpiRemoveFixedEventHandler(event, acpi_event_sleep_button_sleep);
-
     return_VALUE (0);
 }

-- 
Rudolf Cejka <cejkar at fit.vutbr.cz> http://www.fit.vutbr.cz/~cejkar
Brno University of Technology, Faculty of Information Technology
Bozetechova 2, 612 66  Brno, Czech Republic
Received on Thu Feb 19 2004 - 01:43:51 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:43 UTC