* Fix a bug in cpu_lwp_exit() which could cause a TAILQ assertion due to
a thread not being properly removed from the tsleep queue.
td->td_gd->gd_cnt.v_swtch++;
crit_enter_quick(td);
+ if (td->td_flags & TDF_TSLEEPQ)
+ tsleep_remove(td);
lwkt_deschedule_self(td);
lwkt_remove_tdallq(td);
cpu_thread_exit();
td->td_gd->gd_cnt.v_swtch++;
crit_enter_quick(td);
+ if (td->td_flags & TDF_TSLEEPQ)
+ tsleep_remove(td);
lwkt_deschedule_self(td);
lwkt_remove_tdallq(td);
cpu_thread_exit();
td->td_gd->gd_cnt.v_swtch++;
crit_enter_quick(td);
+ if (td->td_flags & TDF_TSLEEPQ)
+ tsleep_remove(td);
lwkt_deschedule_self(td);
lwkt_remove_tdallq(td);
cpu_thread_exit();