summaryrefslogtreecommitdiff
path: root/common/x86_power.c
diff options
context:
space:
mode:
authorLouis Yung-Chieh Lo <yjlou@chromium.org>2012-02-10 12:11:42 +0800
committerLouis Yung-Chieh Lo <yjlou@chromium.org>2012-02-10 12:11:42 +0800
commit186c81dcac9ae96a1ace3ad5bf147fbf8fd35c50 (patch)
tree4a98e4776c47536d90769705c3dfaca8a34ce099 /common/x86_power.c
parent7c01418f9c0a9c9a01bdb25d9c4a5884ec157501 (diff)
downloadchrome-ec-186c81dcac9ae96a1ace3ad5bf147fbf8fd35c50.tar.gz
Send scan code to host when power button is pressed/released.
But only if the system is in S0. Approved at internal gerrit: 11595. BUG=none TEST=tested on bds.
Diffstat (limited to 'common/x86_power.c')
-rw-r--r--common/x86_power.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/common/x86_power.c b/common/x86_power.c
index a911ae436b..d587897d8a 100644
--- a/common/x86_power.c
+++ b/common/x86_power.c
@@ -206,6 +206,12 @@ int x86_power_init(void)
}
/*****************************************************************************/
+int x86_power_in_S0(void) {
+ return state == X86_S0;
+}
+
+
+/*****************************************************************************/
/* Task function */
void x86_power_task(void)