cr50: make device state detect level triggered

The interrupts on all of the gpios detecting if the device is on were
edge triggered. If the rising edge happened in between when the gpio
level was read and when the interrupt was enabled, then the device state
could be falsely detected as off for a short period of time. This change
changes them to GPIO_INT_HIGH.

BUG=none
BRANCH=none
TEST=buildall

Change-Id: I9aa3cff14047cf4f6473c32f2cdc4724afca3414
Signed-off-by: Mary Ruthven <mruthven@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/385164
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
This commit is contained in:
Mary Ruthven
2016-09-14 15:30:23 -07:00
committed by chrome-bot
parent 05d387da78
commit 95ed011a59

View File

@@ -13,9 +13,9 @@
* so we attach two internal GPIOs to the same pad.
*/
GPIO_INT(SYS_RST_L_IN, PIN(1, 0), GPIO_INT_FALLING, sys_rst_asserted)
GPIO_INT(DETECT_AP, PIN(1, 1), GPIO_INT_RISING, device_state_on)
GPIO_INT(DETECT_EC, PIN(1, 2), GPIO_INT_RISING, device_state_on)
GPIO_INT(DETECT_SERVO, PIN(1, 3), GPIO_INT_RISING | GPIO_PULL_DOWN,
GPIO_INT(DETECT_AP, PIN(1, 1), GPIO_INT_HIGH, device_state_on)
GPIO_INT(DETECT_EC, PIN(1, 2), GPIO_INT_HIGH, device_state_on)
GPIO_INT(DETECT_SERVO, PIN(1, 3), GPIO_INT_HIGH | GPIO_PULL_DOWN,
device_state_on)
/* Pull this low to interrupt the AP */