From 862a325fa02357cd9b88619865ce88281d573e93 Mon Sep 17 00:00:00 2001 From: Mulin Chao Date: Tue, 23 Aug 2016 08:24:10 -0700 Subject: [PATCH] npcx: gpio: Enable wake GPIO interrupts prior to hibernate This is necessary after the pending patch to not enable all GPIO interrupts by default. BRANCH=None BUG=chrome-os-partner:56486 TEST=Manual on kevin, run 'hibernate', attach AC and verify wake occurs. Change-Id: I04d2c6edf9fb32b1a6a7e6a5ed4d2c53895e00f0 Signed-off-by: Shawn Nematbakhsh Reviewed-on: https://chromium-review.googlesource.com/374179 Commit-Ready: Shawn N Tested-by: Shawn N Reviewed-by: Aseda Aboagye --- chip/npcx/system.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/chip/npcx/system.c b/chip/npcx/system.c index f9d4d1f584..ec0847cb34 100644 --- a/chip/npcx/system.c +++ b/chip/npcx/system.c @@ -336,8 +336,11 @@ void system_set_gpios_and_wakeup_inputs_hibernate(void) } /* Enable wake-up inputs of hibernate_wake_pins array */ - for (i = 0; i < hibernate_wake_pins_used; i++) + for (i = 0; i < hibernate_wake_pins_used; i++) { gpio_reset(hibernate_wake_pins[i]); + /* Re-enable interrupt for wake-up inputs */ + gpio_enable_interrupt(hibernate_wake_pins[i]); + } } /**