summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRandall Spangler <rspangler@chromium.org>2012-09-06 13:36:32 -0700
committerGerrit <chrome-bot@google.com>2012-09-10 13:06:48 -0700
commit254a8336bf5c5a39b4611d193006b23a4158f478 (patch)
tree0694d513183924245426fdbf25761522df634aea
parentc23dc460731cac6f6377a026b9986fc20527feb9 (diff)
downloadchrome-ec-254a8336bf5c5a39b4611d193006b23a4158f478.tar.gz
Remove old code to clear boot key
This has been deprecated in favor of a host event to trigger recovery mode. BUG=none BRANCH=link TEST=manual 1. Power+Esc+Refresh -> recovery mode 2. Press power -> off 3. Press power -> boots normally (NOT recovery) Change-Id: I9288785ce1c0a446867dc54d1b6ec2f556896688 Signed-off-by: Randall Spangler <rspangler@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/32426 Reviewed-by: Simon Glass <sjg@chromium.org>
-rw-r--r--chip/lm4/keyboard_scan.c10
-rw-r--r--chip/lm4/power_button.c6
-rw-r--r--include/keyboard_scan.h3
3 files changed, 1 insertions, 18 deletions
diff --git a/chip/lm4/keyboard_scan.c b/chip/lm4/keyboard_scan.c
index a26a1fe116..4d33e1cd73 100644
--- a/chip/lm4/keyboard_scan.c
+++ b/chip/lm4/keyboard_scan.c
@@ -299,16 +299,6 @@ enum boot_key keyboard_scan_get_boot_key(void)
return boot_key_value;
}
-void keyboard_scan_clear_boot_key(void)
-{
- boot_key_value = BOOT_KEY_OTHER;
-
-#ifdef CONFIG_TASK_POWERBTN
- /* Wake the power button task to update the recovery switch state */
- task_wake(TASK_ID_POWERBTN);
-#endif
-}
-
int keyboard_scan_init(void)
{
/* Configure GPIO */
diff --git a/chip/lm4/power_button.c b/chip/lm4/power_button.c
index 0da44db822..db96cc1625 100644
--- a/chip/lm4/power_button.c
+++ b/chip/lm4/power_button.c
@@ -213,10 +213,8 @@ static void lid_switch_open(uint64_t tnow)
update_backlight();
host_set_single_event(EC_HOST_EVENT_LID_OPEN);
- /* If the chipset is off, clear keyboard recovery and send a power
- * button pulse to wake up the chipset. */
+ /* If the chipset is off, send a power button pulse to wake it up */
if (chipset_in_state(CHIPSET_STATE_ANY_OFF)) {
- keyboard_scan_clear_boot_key();
chipset_exit_hard_off();
set_pwrbtn_to_pch(0);
pwrbtn_state = PWRBTN_STATE_LID_OPEN;
@@ -376,8 +374,6 @@ static void state_machine(uint64_t tnow)
switch (pwrbtn_state) {
case PWRBTN_STATE_PRESSED:
if (chipset_in_state(CHIPSET_STATE_ANY_OFF)) {
- /* Clear keyboard recovery */
- keyboard_scan_clear_boot_key();
/*
* Chipset is off, so wake the chipset and send it a
* long enough pulse to wake up. After that we'll
diff --git a/include/keyboard_scan.h b/include/keyboard_scan.h
index 98ff5db826..0fa526ee48 100644
--- a/include/keyboard_scan.h
+++ b/include/keyboard_scan.h
@@ -31,9 +31,6 @@ enum boot_key {
*/
enum boot_key keyboard_scan_get_boot_key(void);
-/* Clear the boot key state. */
-void keyboard_scan_clear_boot_key(void);
-
/* Return non-zero if recovery key was pressed at boot. */
int keyboard_scan_recovery_pressed(void);