From: Con Kolivas > Woops my bad. Seems putting things even at the start of the expired array > can induce a corner case. Will post an O11.1 in a few mins to back out that > part. Here is O11.1int which backs out that part. This was only of minor help anyway so backing it out still makes the other O11 changes worthwhile. A full O11.1 patch against 2.6.0-test2 is available on my website. 25-akpm/kernel/sched.c | 19 ++++--------------- 1 files changed, 4 insertions(+), 15 deletions(-) diff -puN kernel/sched.c~o11int.1 kernel/sched.c --- 25/kernel/sched.c~o11int.1 Tue Jul 29 18:06:39 2003 +++ 25-akpm/kernel/sched.c Tue Jul 29 18:06:39 2003 @@ -310,14 +310,6 @@ static inline void enqueue_task(struct t p->array = array; } -static inline void enqueue_head_task(struct task_struct *p, prio_array_t *array) -{ - list_add(&p->run_list, array->queue + p->prio); - __set_bit(p->prio, array->bitmap); - array->nr_active++; - p->array = array; -} - /* * effective_prio - return the priority that is based on the static * priority but is modified by bonuses/penalties. @@ -1299,13 +1291,10 @@ void scheduler_tick(int user_ticks, int * run out of sleep_avg to be expired, and when they * do they are put at the start of the expired array */ - if (unlikely(p->interactive_credit)){ - if (p->sleep_avg){ - enqueue_task(p, rq->active); - goto out_unlock; - } - enqueue_head_task(p, rq->expired); - } else + if (unlikely(p->interactive_credit && p->sleep_avg)){ + enqueue_task(p, rq->active); + goto out_unlock; + } enqueue_task(p, rq->expired); } else enqueue_task(p, rq->active); _