Loading kernel/sched/fair.c +3 −9 Original line number Diff line number Diff line Loading @@ -5456,11 +5456,10 @@ bail_inter_cluster_balance(struct lb_env *env, struct sd_lb_stats *sds) { int nr_cpus; if (sds->this_group_capacity <= sds->busiest_group_capacity) if (group_rq_capacity(sds->this) <= group_rq_capacity(sds->busiest)) return 0; if (sds->busiest_nr_big_tasks && sds->this_group_capacity > sds->busiest_group_capacity) if (sds->busiest_nr_big_tasks) return 0; nr_cpus = cpumask_weight(sched_group_cpus(sds->busiest)); Loading Loading @@ -5796,15 +5795,10 @@ static bool update_sd_pick_busiest(struct lb_env *env, struct sched_group *sg, struct sg_lb_stats *sgs) { unsigned long capacity; if (sgs->avg_load <= sds->max_load) return false; capacity = (env->idle == CPU_NOT_IDLE) ? sgs->group_capacity : cpumask_weight(sched_group_cpus(sg)); if (sgs->sum_nr_running > capacity) { if (sgs->sum_nr_running > sgs->group_capacity) { env->flags &= ~LBF_PWR_ACTIVE_BALANCE; return true; } Loading kernel/sched/sched.h +6 −0 Original line number Diff line number Diff line Loading @@ -673,6 +673,12 @@ static inline unsigned int group_first_cpu(struct sched_group *group) extern int group_balance_cpu(struct sched_group *sg); /* * Returns the rq capacity of any rq in a group. This does not play * well with groups where rq capacity can change independently. */ #define group_rq_capacity(group) capacity(cpu_rq(group_first_cpu(group))) #endif /* CONFIG_SMP */ #include "stats.h" Loading Loading
kernel/sched/fair.c +3 −9 Original line number Diff line number Diff line Loading @@ -5456,11 +5456,10 @@ bail_inter_cluster_balance(struct lb_env *env, struct sd_lb_stats *sds) { int nr_cpus; if (sds->this_group_capacity <= sds->busiest_group_capacity) if (group_rq_capacity(sds->this) <= group_rq_capacity(sds->busiest)) return 0; if (sds->busiest_nr_big_tasks && sds->this_group_capacity > sds->busiest_group_capacity) if (sds->busiest_nr_big_tasks) return 0; nr_cpus = cpumask_weight(sched_group_cpus(sds->busiest)); Loading Loading @@ -5796,15 +5795,10 @@ static bool update_sd_pick_busiest(struct lb_env *env, struct sched_group *sg, struct sg_lb_stats *sgs) { unsigned long capacity; if (sgs->avg_load <= sds->max_load) return false; capacity = (env->idle == CPU_NOT_IDLE) ? sgs->group_capacity : cpumask_weight(sched_group_cpus(sg)); if (sgs->sum_nr_running > capacity) { if (sgs->sum_nr_running > sgs->group_capacity) { env->flags &= ~LBF_PWR_ACTIVE_BALANCE; return true; } Loading
kernel/sched/sched.h +6 −0 Original line number Diff line number Diff line Loading @@ -673,6 +673,12 @@ static inline unsigned int group_first_cpu(struct sched_group *group) extern int group_balance_cpu(struct sched_group *sg); /* * Returns the rq capacity of any rq in a group. This does not play * well with groups where rq capacity can change independently. */ #define group_rq_capacity(group) capacity(cpu_rq(group_first_cpu(group))) #endif /* CONFIG_SMP */ #include "stats.h" Loading