mirror of https://github.com/l4ka/pistachio.git
HSCHED: fix endless loop on migrated thred during accounting CPU time
This commit is contained in:
parent
6c1d840678
commit
408e097619
|
@ -20,13 +20,13 @@ EXTERN_TRACEPOINT(SCHEDULE_IDLE);
|
|||
INLINE void hs_sched_ktcb_t::account_pass()
|
||||
{
|
||||
tcb_t *tcb = addr_to_tcb(this);
|
||||
while( tcb != get_idle_tcb() )
|
||||
while (tcb->get_global_id() != IDLETHREAD )
|
||||
{
|
||||
ASSERT(tcb->is_local_cpu());
|
||||
sched_ktcb_t *sktcb = &tcb->sched_state;
|
||||
|
||||
TRACEPOINT (SCHEDULE_DETAILS, "account pass %t %U += %d\n",
|
||||
tcb, sktcb->get_pass(), sktcb->get_stride());
|
||||
tcb, sktcb->get_pass(), sktcb->get_stride());
|
||||
|
||||
sktcb->set_pass(sktcb->get_pass() + sktcb->get_stride());
|
||||
|
||||
|
|
Loading…
Reference in New Issue