HAL_Linux: added _main_ctx

This commit is contained in:
Andrew Tridgell 2017-10-30 08:09:36 +11:00
parent 0eb25fcc74
commit 25678a59e7
2 changed files with 4 additions and 0 deletions

View File

@ -83,6 +83,8 @@ void Scheduler::init()
SCHED_THREAD(io, IO), SCHED_THREAD(io, IO),
}; };
_main_ctx = pthread_self();
#if !APM_BUILD_TYPE(APM_BUILD_Replay) #if !APM_BUILD_TYPE(APM_BUILD_Replay)
// we don't run Replay in real-time... // we don't run Replay in real-time...
mlockall(MCL_CURRENT|MCL_FUTURE); mlockall(MCL_CURRENT|MCL_FUTURE);

View File

@ -114,9 +114,11 @@ private:
uint64_t _stopped_clock_usec; uint64_t _stopped_clock_usec;
uint64_t _last_stack_debug_msec; uint64_t _last_stack_debug_msec;
pthread_t _main_ctx;
Semaphore _timer_semaphore; Semaphore _timer_semaphore;
Semaphore _io_semaphore; Semaphore _io_semaphore;
}; };
} }