- In sched_prio() check to see if the kse is assigned to a runq as the

check for TD_ON_RUNQ() no longer means the thread is really on a run-
   queue.  I suspect this state should be re-evaluated as it must mean
   something else now.  This fixes ULE+KSE+PREEMPTION on UP x86.
This commit is contained in:
jeff 2004-10-30 07:35:53 +00:00
parent c823d3b356
commit d8f987468c

View File

@ -1226,7 +1226,7 @@ sched_prio(struct thread *td, u_char prio)
* queue. We still call adjustrunqueue below in case kse
* needs to fix things up.
*/
if (prio < td->td_priority && ke &&
if (prio < td->td_priority && ke && ke->ke_runq != NULL &&
(ke->ke_flags & KEF_ASSIGNED) == 0 &&
ke->ke_runq != KSEQ_CPU(ke->ke_cpu)->ksq_curr) {
runq_remove(ke->ke_runq, ke);