Dokumentation
Guarded Class Reference
A handy interface to protect critical sections. More...
#include <interrupt/guarded.h>
Public Member Functions | |
Guarded (bool forceInterruptEnable=false) | |
Constructor: Enter guarded section. More... | |
~Guarded () | |
Destructor: Leave guarded section. | |
Detailed Description
A handy interface to protect critical sections.
This exploits the way how the C++ compiler automatically creates constructor and destructor calls in the code, especially when the scope in which an object was declared is left.
So if you enter a critical section using its constructor and leave it again in the destructor, you can easily mark critical code areas as follows:
Constructor & Destructor Documentation
|
inlineexplicit |
Constructor: Enter guarded section.
- Parameters
-
forceInterruptEnable if set, interrupts will be enabled after switching this core to epilogue level (but before waiting for the big kernel lock), even if interrupts were disabled.
The documentation for this class was generated from the following file:
- interrupt/guarded.h