From 1a5632cba0861a74936006a4b464e85da4581548 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20Th=C3=A9baudeau?= Date: Thu, 9 Apr 2015 00:44:51 +0200 Subject: [PATCH] cc2538: gpio: Fix missed power-up interrupts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Power-up interrupts do not always update the regular interrupt status. Because of that, in order not to miss power-up interrupts, the ISR must handle both the regular and the power-up interrupt statuses. Signed-off-by: Benoît Thébaudeau --- cpu/cc2538/dev/gpio.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cpu/cc2538/dev/gpio.c b/cpu/cc2538/dev/gpio.c index 6d3f1fc94..cce0c6b22 100644 --- a/cpu/cc2538/dev/gpio.c +++ b/cpu/cc2538/dev/gpio.c @@ -93,7 +93,8 @@ gpio_port_isr(uint8_t port) base = GPIO_PORT_TO_BASE(port); - notify(GPIO_GET_MASKED_INT_STATUS(base), port); + notify(GPIO_GET_MASKED_INT_STATUS(base) | GPIO_GET_POWER_UP_INT_STATUS(port), + port); GPIO_CLEAR_INTERRUPT(base, 0xFF); GPIO_CLEAR_POWER_UP_INTERRUPT(port, 0xFF);