summaryrefslogtreecommitdiffstats
path: root/sys/kern/kern_switch.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/kern_switch.c')
-rw-r--r--sys/kern/kern_switch.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/kern/kern_switch.c b/sys/kern/kern_switch.c
index b6ae79d..348a521b8 100644
--- a/sys/kern/kern_switch.c
+++ b/sys/kern/kern_switch.c
@@ -155,11 +155,10 @@ choosethread(void)
} else {
/* Pretend the idle thread was on the run queue. */
td = PCPU_GET(idlethread);
- /* Simulate that it was on the run queue */
- td->td_state = TDS_RUNQ;
td->td_kse->ke_state = KES_UNQUEUED;
CTR1(KTR_RUNQ, "choosethread: td=%p (idle)", td);
}
+ td->td_state = TDS_RUNNING;
return (td);
}
OpenPOWER on IntegriCloud