Thank you for your reply,Nikita description of my system: Hardware:nrf51822,pca10001 Software:sdk5.20,run the softdevice s120
I call these functions sd_nvic_SetPriority()/sd_nvic_EnableIRQ() is for use GPIOTE interrupt ,if i push a button ,it should be into a GPIOTE_handler,but if i call sd_nvic_SetPriority()/sd_nvic_EnableIRQ(),it will into a hardfault,if i not use sd_nvic_SetPriority(),the hardfault will not occur,but if i push button ,the interrupt will not occur.
but if i not use softdevice,call nvic_EnableIRQ,every thing will be normal.