From: Ingo Molnar Helper function for later patches --- 25-akpm/kernel/sched.c | 15 +++++++++++++++ 1 files changed, 15 insertions(+) diff -puN kernel/sched.c~sched-enqueue_task_head kernel/sched.c --- 25/kernel/sched.c~sched-enqueue_task_head 2004-05-05 21:00:37.010737616 -0700 +++ 25-akpm/kernel/sched.c 2004-05-05 21:00:37.016736704 -0700 @@ -331,6 +331,21 @@ static void enqueue_task(struct task_str p->array = array; } +#ifdef CONFIG_SMP +/* + * Used by the migration code - we pull tasks from the head of the + * remote queue so we want these tasks to show up at the head of the + * local queue: + */ +static inline void enqueue_task_head(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; +} +#endif + /* * effective_prio - return the priority that is based on the static * priority but is modified by bonuses/penalties. _