Messages in this thread Patch in this message | | | Date | Thu, 15 Aug 2013 13:14:28 +0200 | From | Peter Zijlstra <> | Subject | Re: [PATCH v3 3/3] sched: clean-up struct sd_lb_stat |
| |
Another little diff.
--- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -4647,8 +4647,10 @@ static inline void update_sd_lb_stats(st int local_group; local_group = cpumask_test_cpu(env->dst_cpu, sched_group_cpus(sg)); - if (local_group) + if (local_group) { + sds->this = sg; sgs = &sds->this_stat; + } memset(sgs, 0, sizeof(*sgs)); update_sg_lb_stats(env, sg, load_idx, local_group, sgs); @@ -4671,9 +4673,7 @@ static inline void update_sd_lb_stats(st sds->total_load += sgs->group_load; sds->total_pwr += sg->sgp->power; - if (local_group) - sds->this = sg; - else if (update_sd_pick_busiest(env, sds, sg, sgs)) { + if (!local_group && update_sd_pick_busiest(env, sds, sg, sgs)) { sds->busiest = sg; sds->busiest_stat = *sgs; }
| |