static unsigned long load_balance_other_rr(struct rq *this_rq, int this_cpu, struct rq *busiest, unsigned long max_load_move, struct sched_domain *sd, enum cpu_idle_type idle, int *all_pinned, int *this_best_prio) { struct rq_iterator other_rr_rq_iterator; other_rr_rq_iterator.start = load_balance_start_other_rr; other_rr_rq_iterator.next = load_balance_next_other_rr; /* pass 'busiest' rq argument into * load_balance_[start|next]_other_rr iterators */ other_rr_rq_iterator.arg = busiest; return balance_tasks(this_rq, this_cpu, busiest, max_load_move, sd, idle, all_pinned, this_best_prio, &other_rr_rq_iterator); }
static unsigned long load_balance_rt(struct rq *this_rq, int this_cpu, struct rq *busiest, unsigned long max_nr_move, unsigned long max_load_move, struct sched_domain *sd, enum cpu_idle_type idle, int *all_pinned, int *this_best_prio) { int nr_moved; struct rq_iterator rt_rq_iterator; unsigned long load_moved; rt_rq_iterator.start = load_balance_start_rt; rt_rq_iterator.next = load_balance_next_rt; /* pass 'busiest' rq argument into * load_balance_[start|next]_rt iterators */ rt_rq_iterator.arg = busiest; nr_moved = balance_tasks(this_rq, this_cpu, busiest, max_nr_move, max_load_move, sd, idle, all_pinned, &load_moved, this_best_prio, &rt_rq_iterator); return load_moved; }