[riot-notifications] [RIOT-OS/RIOT] core/*: many important system functions illegal inside ISRs (#10488)

Gunar Schorcht notifications at github.com
Fri Nov 30 07:23:14 CET 2018


@ZetaR60 
> The thread would have a queue for callbacks usable by anything that needs to be triggered by an interrupt but uses functions that are not legal for use within an ISR.

That was exactly that what I had in mind when I said in #10496 "This concept of having only one handler thread might also be a solution for the problem in #10488 for other drivers that require access to SPI or I2C".

If there is only one handler thread for driver ISRs that need to invoke blocking functions, the advantage would be that the number of threads is kept small and resources are saved. The disadvantage would be that the interrupt events are handled in the order of the handler queue, which determines the priority and possibly causes unnecessary blocks. For example, if you have interrupt events from two different drivers. One driver needs access to I2C and the other driver requires access to SPI or another I2C bus. In this case, the I2C access of the first driver must be completed before the interrupt event of the second driver can be handled, even if it does not interfere. That is, the first driver blocks the seconds driver, although it would not be necessary.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/issues/10488#issuecomment-443104264
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20181129/bdcdae07/attachment.html>


More information about the notifications mailing list