From ef8ea3a09d70284e882870a744ef783d858b6f8b Mon Sep 17 00:00:00 2001 From: jeff Date: Fri, 4 Feb 2005 17:22:46 +0000 Subject: - Add ke_runq == NULL to the conditions which will cause us to abort adjusting timeshare loads in sched_class(). This is only important if the thread has never run, otherwise the state checks should work as expected. --- sys/kern/sched_ule.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/kern/sched_ule.c b/sys/kern/sched_ule.c index 696d700..6c14913 100644 --- a/sys/kern/sched_ule.c +++ b/sys/kern/sched_ule.c @@ -1534,8 +1534,8 @@ sched_class(struct ksegrp *kg, int class) oclass = PRI_BASE(kg->kg_pri_class); FOREACH_THREAD_IN_GROUP(kg, td) { ke = td->td_kse; - if (ke->ke_state != KES_ONRUNQ && - ke->ke_state != KES_THREAD) + if ((ke->ke_state != KES_ONRUNQ && + ke->ke_state != KES_THREAD) || ke->ke_runq == NULL) continue; kseq = KSEQ_CPU(ke->ke_cpu); -- cgit v1.1