w83627hf: add method to retrieve wake event source register to ASL include
authorChristoph Grenz <christophg+cb@grenz-bonn.de>
Wed, 19 Oct 2011 00:25:08 +0000 (02:25 +0200)
committerStefan Reinauer <stefan.reinauer@coreboot.org>
Fri, 28 Oct 2011 20:30:06 +0000 (22:30 +0200)
Add a method WAKS to devtree.asl which returns the wake-up source register
to simplify retrieving the wake source e.g. in \_WAK.

Change-Id: Ia258f8fc9ff79b18391c55464da73863889e2255
Signed-off-by: Christoph Grenz <christophg+cb@grenz-bonn.de>
Reviewed-on: http://review.coreboot.org/297
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
src/superio/winbond/w83627hf/devtree.asl

index cbc132d467e0dbe2b4834f7210c10ac939f36d3e..aa18841e629197550b340200b58ae20a110b5a08 100644 (file)
@@ -1503,5 +1503,22 @@ Scope (\_SB)
                        }
                }
                #endif
+
+               /* Returns the wake source register.
+                  It is cleared after reading.
+                  Bit 0: Keyboard wake-up event
+                  Bit 1: Mouse wake-up event
+                  Bit 2: Power button event
+                  Bit 3: CIR wake-up event
+                  Bit 4: Power loss event
+                  Bit 5: VSB power loss status
+               */
+               Method (WAKS) {
+                       ENCM ()
+                       Store (0x0A, LDN)
+                       Store (CRE3, Local0)
+                       EXCM ()
+                       Return (Local0)
+               }
        }
 }