You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
The documentations says that semaphores could be used from ISRs if they don't block. When I'm trying to use them from ISRs I'm sometimes getting assertion failures with message "recursive spinlock" with address of sem.c:lock (nrfconnect/sdk-nrf#3003 (comment)).
From reading the documentation for BASEPRI register I understand that it cannot be used alone to block priority-0 ISRs, this would break spin locks used from such interrupts.
I would like to clarify if my suspicion is correct, and if so, the limitation be documented somewhere.
Expected behavior
Semaphores could be used from all ISR priorities as documented.
Impact
In my case I can avoid using semaphores from ISRs.
The text was updated successfully, but these errors were encountered:
eugmes
changed the title
ARM Cortex-M4: Semaphores could not be used in IRQs with priority 0?
ARM Cortex-M4: Semaphores could not be used in ISRs with priority 0?
Oct 2, 2020
Describe the bug
The documentations says that semaphores could be used from ISRs if they don't block. When I'm trying to use them from ISRs I'm sometimes getting assertion failures with message "recursive spinlock" with address of
sem.c:lock
(nrfconnect/sdk-nrf#3003 (comment)).From reading the documentation for
BASEPRI
register I understand that it cannot be used alone to block priority-0 ISRs, this would break spin locks used from such interrupts.I would like to clarify if my suspicion is correct, and if so, the limitation be documented somewhere.
Expected behavior
Semaphores could be used from all ISR priorities as documented.
Impact
In my case I can avoid using semaphores from ISRs.
The text was updated successfully, but these errors were encountered: