diff --git a/core/sched.cc b/core/sched.cc index bd4c43ce645d8bd97a66fb5a37bd6f92f45f8fb0..c8539e0ca707b6ecadd5b5e6594f95ddb9476056 100644 --- a/core/sched.cc +++ b/core/sched.cc @@ -264,7 +264,7 @@ void thread::wake() // FIXME: warrant an interruption if (_cpu != current()->tcpu()) { wakeup_ipi.send(_cpu); - } else if (arch::irq_enabled()) { + } else if (arch::irq_enabled() && !preempt_counter) { _cpu->schedule(); // We'll also reschedule at the end of an interrupt if needed }