The Completely Fair Scheduling Class

All information that the core scheduler needs to know about the completely fair scheduler is contained in fair_sched_class:

kernel/sched_fair.c static const struct sched_class fair_sched_class = { .next = &idle_sched_class, .enqueue_task = enqueue_task_fair, .dequeue_task = dequeue_task_fair, .yield_task = yield_task_fair,

.check_preempt_curr = check_preempt_wakeup,

.pick_next_task = pick_next_task_fair, .put_prev_task = put_prev_task_fair,

.set_curr_task = set_curr_task_fair, .task_tick = task_tick_fair, .task_new = task_new_fair,

We have seen in the previous discussion when these functions are called by the main scheduler and will examine in the following how they are implemented for CFS.

Continue reading here: Data Structures

Was this article helpful?

0 0