sched: remove activate_idle_task()

cpu_down() code is ok wrt sched_idle_next() placing the 'idle' task not
at the beginning of the queue.

So get rid of activate_idle_task() and make use of activate_task() instead.
It is the same as activate_task(), except for the update_rq_clock(rq) call
that is redundant.

Code size goes down:

text data bss dec hex filename
47853 3934 336 52123 cb9b sched.o.before
47828 3934 336 52098 cb82 sched.o.after

Signed-off-by: Dmitry Adamushko <dmitry.adamushko@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>

authored by Dmitry Adamushko and committed by Ingo Molnar 94bc9a7b ce96b5ac

+4 -18
+4 -18
kernel/sched.c
··· 5282 5282 } 5283 5283 5284 5284 /* 5285 - * activate_idle_task - move idle task to the _front_ of runqueue. 5286 - */ 5287 - static void activate_idle_task(struct task_struct *p, struct rq *rq) 5288 - { 5289 - update_rq_clock(rq); 5290 - 5291 - if (p->state == TASK_UNINTERRUPTIBLE) 5292 - rq->nr_uninterruptible--; 5293 - 5294 - enqueue_task(rq, p, 0); 5295 - inc_nr_running(p, rq); 5296 - } 5297 - 5298 - /* 5299 5285 * Schedules idle task to be the next runnable task on current CPU. 5300 - * It does so by boosting its priority to highest possible and adding it to 5301 - * the _front_ of the runqueue. Used by CPU offline code. 5286 + * It does so by boosting its priority to highest possible. 5287 + * Used by CPU offline code. 5302 5288 */ 5303 5289 void sched_idle_next(void) 5304 5290 { ··· 5304 5318 5305 5319 __setscheduler(rq, p, SCHED_FIFO, MAX_RT_PRIO-1); 5306 5320 5307 - /* Add idle task to the _front_ of its priority queue: */ 5308 - activate_idle_task(p, rq); 5321 + update_rq_clock(rq); 5322 + activate_task(rq, p, 0); 5309 5323 5310 5324 spin_unlock_irqrestore(&rq->lock, flags); 5311 5325 }