[riot-notifications] [RIOT-OS/RIOT] core: add irq_is_enabled() function to irq interface (#11117)

Gunar Schorcht notifications at github.com
Fri Mar 8 19:15:11 CET 2019

gschorcht commented on this pull request.

> @@ -60,6 +61,14 @@ unsigned irq_enable(void);
 void irq_restore(unsigned state);
+ * @brief   Test if IRQs are currently enabled
+ *
+ * @return  0 (false) if IRQs are currently disabled
+ * @return  != 0 (true) if IRQs are currently enabled

I'm not sure if an undefined return value would really be the best choice? Either the architecture implicitly disables the interrupts when an ISR is entered, or the architecture also allows checking the state within an ISR.

You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190308/1e6c7b40/attachment.html>

More information about the notifications mailing list