Add CPU ID lock

This commit is contained in:
Jeremy Soller 2016-10-23 11:24:10 -06:00
parent 9836b3cb56
commit 221b4c0116
3 changed files with 17 additions and 11 deletions

View file

@ -50,6 +50,7 @@ pub fn init() {
context.kfx = Some(fx);
context.status = Status::Runnable;
context.running = true;
context.cpuid = Some(::cpu_id());
CONTEXT_ID.store(context.id, Ordering::SeqCst);
}