summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/ec/lenovo/h8/acpi/ec.asl14
-rw-r--r--src/ec/lenovo/h8/acpi/thinkpad.asl12
2 files changed, 17 insertions, 9 deletions
diff --git a/src/ec/lenovo/h8/acpi/ec.asl b/src/ec/lenovo/h8/acpi/ec.asl
index 8a1b9c4343..327a2cfe1f 100644
--- a/src/ec/lenovo/h8/acpi/ec.asl
+++ b/src/ec/lenovo/h8/acpi/ec.asl
@@ -75,6 +75,20 @@ Device(EC)
DKR3, 1 /* Dock register 3 */
}
+ /* Called on OperationRegion driver changes */
+ Method (_REG, 2, NotSerialized)
+ {
+ /* Wait for ERAM driver loaded */
+ if (LEqual(Arg1, One)) {
+ /* Fill HKEY defaults on first boot */
+ if (LEqual(^HKEY.INIT, Zero)) {
+ Store (BTEB, ^HKEY.WBDC)
+ Store (WWEB, ^HKEY.WWAN)
+ Store (One, ^HKEY.INIT)
+ }
+ }
+ }
+
Method (_CRS, 0, Serialized)
{
Name (ECMD, ResourceTemplate()
diff --git a/src/ec/lenovo/h8/acpi/thinkpad.asl b/src/ec/lenovo/h8/acpi/thinkpad.asl
index 8fb5716531..1997d08549 100644
--- a/src/ec/lenovo/h8/acpi/thinkpad.asl
+++ b/src/ec/lenovo/h8/acpi/thinkpad.asl
@@ -157,6 +157,9 @@ Device (HKEY)
Return (\_SB.PCI0.LPCB.EC.GSTS)
}
+ /* Set to one on first boot */
+ Name (INIT, 0)
+
/* Has thinkpad_acpi module loaded */
Name (HAST, 0)
@@ -305,15 +308,6 @@ Device (HKEY)
}
/*
- * Store initial state
- */
- Method (_INI, 0, NotSerialized)
- {
- Store (\_SB.PCI0.LPCB.EC.BTEB, WBDC)
- Store (\_SB.PCI0.LPCB.EC.WWEB, WWAN)
- }
-
- /*
* Called from _WAK
*/
Method (WAKE, 1)