summaryrefslogtreecommitdiff
path: root/src/mainboard/google/auron/ec.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/google/auron/ec.c')
-rw-r--r--src/mainboard/google/auron/ec.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/mainboard/google/auron/ec.c b/src/mainboard/google/auron/ec.c
index 3fc5373096..0589864d7f 100644
--- a/src/mainboard/google/auron/ec.c
+++ b/src/mainboard/google/auron/ec.c
@@ -29,10 +29,17 @@ void mainboard_ec_init(void)
.s5_wake_events = MAINBOARD_EC_S5_WAKE_EVENTS,
};
+ int s3_wakeup = acpi_is_wakeup_s3();
+
printk(BIOS_DEBUG, "mainboard_ec_init\n");
post_code(0xf0);
- google_chromeec_events_init(&info, acpi_is_wakeup_s3());
+ google_chromeec_events_init(&info, s3_wakeup);
+ if (s3_wakeup) {
+ /* Clear pending events. */
+ while (google_chromeec_get_event() != 0)
+ ;
+ }
post_code(0xf1);
}