Hi Nordic--
Our custom nRF51822 design has 13 signals routed into the app_buttons module through the GPIO -> GPIOTE->PORT -> nrf_drv_gpiote.c -> app_buttons.c path. For a yet-to-be-determined reason, one of the signals "flaps" briefly during initial power-on; that is, the state of the pin rapidly changes from high to low and back again. Because the transition happens so fast, this results in a GPIOTE PORT interrupt in which none of the 13 signals have their SENSE value changed (I have debugged this in nrf_drv_gpiote.c's GPIOTE_IrqHandler code). At the termination of the interrupt, I believe that the pin which triggered the interrupt is still asserting its DETECT signal, because if I enter system POWER OFF state, the chip immediately wakes up. Also, after the interrupt, none of the 13 signals generate any additional interrupts, which is a big problem. It seems the fact that the firmware is unable to absolutely determine which pin triggered the PORT interrupt seems to be an unfortunate limitation in the chip as discussed here and here.
My question is: given my ability to detect when the problem has occurred (GPIOTE_IrqHandler completes without changing any pin state information), and given that in our specific circumstance, the problem only happens during initial power on, is there any way to completely reset the GPIO & GPIOTE hardware blocks in such a way that any phantom DETECT signals are totally cleared out? Maybe an undocumented register that controls the power to the GPIO hardware block (analogous to NRF_GPIOTE->POWER)? This is with SDK 9/SD 110 v8, and I'm using the stock, un-modified implementation of nrf_drv_gpiote.c and app_buttons.c.