nrf5x: gpiote uninit only needs to be run if input pin is configured for irq (or output)

pull/6021/head
Andrew Leech 2018-02-06 12:48:39 +11:00
parent 964e6e74fb
commit f639777dce
1 changed files with 1 additions and 1 deletions

View File

@ -112,7 +112,7 @@ static void gpiote_pin_uninit(uint8_t pin)
if ((m_gpio_cfg[pin].direction == PIN_OUTPUT) && (!m_gpio_cfg[pin].used_as_irq)) {
nrf_drv_gpiote_out_uninit(pin);
}
else {
else if (m_gpio_cfg[pin].used_as_irq) {
nrf_drv_gpiote_in_uninit(pin);
}
}