mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2025-04-24 18:31:31 +00:00
Don't check EventDispatcher::thread_event_loop before using.
If static methods are getting called, variable is already set.
This commit is contained in:
parent
9444d21c12
commit
2b7e763619
@ -40,16 +40,12 @@ public:
|
|||||||
void request_stop();
|
void request_stop();
|
||||||
|
|
||||||
static inline void events_flag(const eventmask_t events) {
|
static inline void events_flag(const eventmask_t events) {
|
||||||
if( thread_event_loop ) {
|
|
||||||
chEvtSignal(thread_event_loop, events);
|
chEvtSignal(thread_event_loop, events);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
static inline void events_flag_isr(const eventmask_t events) {
|
static inline void events_flag_isr(const eventmask_t events) {
|
||||||
if( thread_event_loop ) {
|
|
||||||
chEvtSignalI(thread_event_loop, events);
|
chEvtSignalI(thread_event_loop, events);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
static Thread* thread_event_loop;
|
static Thread* thread_event_loop;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user