summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mainboard/hp/pavilion_m6_1035dx/acpi/gpe.asl9
-rw-r--r--src/mainboard/hp/pavilion_m6_1035dx/acpi/mainboard.asl17
-rw-r--r--src/mainboard/hp/pavilion_m6_1035dx/dsdt.asl2
3 files changed, 28 insertions, 0 deletions
diff --git a/src/mainboard/hp/pavilion_m6_1035dx/acpi/gpe.asl b/src/mainboard/hp/pavilion_m6_1035dx/acpi/gpe.asl
index a240308c78..f228691fc3 100644
--- a/src/mainboard/hp/pavilion_m6_1035dx/acpi/gpe.asl
+++ b/src/mainboard/hp/pavilion_m6_1035dx/acpi/gpe.asl
@@ -54,6 +54,15 @@ Scope(\_GPE) { /* Start Scope GPE */
/* DBGO("\\_GPE\\_L11\n") */
}
+ /* Lid switch opened or closed */
+ Method(_L16) {
+ Store("Lid status changed", Debug)
+ /* Flip trigger polarity */
+ Not(LPOL, LPOL)
+ /* Notify lid object of status change */
+ Notify(\_SB.LID, 0x80)
+ }
+
/* GPIO0 or GEvent8 event */
Method(_L18) {
/* DBGO("\\_GPE\\_L18\n") */
diff --git a/src/mainboard/hp/pavilion_m6_1035dx/acpi/mainboard.asl b/src/mainboard/hp/pavilion_m6_1035dx/acpi/mainboard.asl
index 6a100387ce..ecca0872ff 100644
--- a/src/mainboard/hp/pavilion_m6_1035dx/acpi/mainboard.asl
+++ b/src/mainboard/hp/pavilion_m6_1035dx/acpi/mainboard.asl
@@ -57,6 +57,14 @@
GE22, 1, /* General event 22 - connected to lid switch */
}
+ /* SMI/SCI control block -- hardcoded to 0xfed80200 by AGESA */
+ OperationRegion (SMIX, SystemMemory, 0xfed80200, 0x100)
+ Field (SMIX, AnyAcc, NoLock, Preserve) {
+ Offset (0x08), /* SCI level: 0 = active low, 1 = active high */
+ , 22,
+ LPOL, 1, /* SCI22 trigger polarity - lid switch */
+ }
+
/*
* Used by EC code on certain events
*
@@ -75,10 +83,19 @@ Scope (\_SB) {
Device (LID)
{
Name(_HID, EisaId("PNP0C0D"))
+ Name(_PRW, Package () {EC_LID_GPE, 0x04}) /* wake from S1-S4 */
Method(_LID, 0)
{
Return (GE22) /* GE pin 22 */
}
+
+ Method (_INI, 0)
+ {
+ /* Make sure lid trigger polarity is set so that we
+ * trigger an SCI when lid status changes.
+ */
+ Not(GE22, LPOL)
+ }
}
Device (MB) {
diff --git a/src/mainboard/hp/pavilion_m6_1035dx/dsdt.asl b/src/mainboard/hp/pavilion_m6_1035dx/dsdt.asl
index c1f1933d61..4783394123 100644
--- a/src/mainboard/hp/pavilion_m6_1035dx/dsdt.asl
+++ b/src/mainboard/hp/pavilion_m6_1035dx/dsdt.asl
@@ -18,6 +18,8 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
*/
+#include "mainboard.h"
+
/* DefinitionBlock Statement */
DefinitionBlock (
"DSDT.AML", /* Output filename */