Use the proper flag for re-enabling certain hardware events (power btn,
authormlarkin <mlarkin@openbsd.org>
Tue, 3 Aug 2010 16:32:40 +0000 (16:32 +0000)
committermlarkin <mlarkin@openbsd.org>
Tue, 3 Aug 2010 16:32:40 +0000 (16:32 +0000)
sleep btn). The (incorrect) flag prevoiously used coincidentally had the
same value, so this shouldn't cause any different behavior than before.

tested on a variety of machines (i386, amd64, sp, mp) - no behavioral
change seen

ok deraadt@

sys/dev/acpi/acpi.c

index fd4170d..7778402 100644 (file)
@@ -1,4 +1,4 @@
-/* $OpenBSD: acpi.c,v 1.197 2010/07/28 14:39:43 marco Exp $ */
+/* $OpenBSD: acpi.c,v 1.198 2010/08/03 16:32:40 mlarkin Exp $ */
 /*
  * Copyright (c) 2005 Thorsten Lockert <tholo@sigmasoft.com>
  * Copyright (c) 2005 Jordan Hargrave <jordan@openbsd.org>
@@ -2036,7 +2036,7 @@ acpi_thread(void *arg)
                        s = spltty();
                        en = acpi_read_pmreg(sc, ACPIREG_PM1_EN, 0);
                        acpi_write_pmreg(sc, ACPIREG_PM1_EN,  0,
-                           en | ACPI_PM1_PWRBTN_STS);
+                           en | ACPI_PM1_PWRBTN_EN);
                        splx(s);
 
                }
@@ -2051,7 +2051,7 @@ acpi_thread(void *arg)
                        s = spltty();
                        en = acpi_read_pmreg(sc, ACPIREG_PM1_EN, 0);
                        acpi_write_pmreg(sc, ACPIREG_PM1_EN,  0,
-                           en | ACPI_PM1_SLPBTN_STS);
+                           en | ACPI_PM1_SLPBTN_EN);
                        splx(s);
                }