[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20140424141826.GU11096@twins.programming.kicks-ass.net>
Date: Thu, 24 Apr 2014 16:18:26 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Alex Shi <alex.shi@...aro.org>
Cc: mingo@...hat.com, morten.rasmussen@....com,
vincent.guittot@...aro.org, daniel.lezcano@...aro.org,
efault@....de, wangyun@...ux.vnet.ibm.com,
linux-kernel@...r.kernel.org, mgorman@...e.de
Subject: Re: [PATCH V5 3/8] sched: remove source_load and target_load
On Wed, Apr 16, 2014 at 10:43:24AM +0800, Alex Shi wrote:
> We have no load_idx any more, so source/target_load always return the
> same value as weighted_cpuload. So we can remove these 2 functions.
That's just not true:
> -/*
> - * Return a low guess at the load of a migration-source cpu weighted
> - * according to the scheduling class and "nice" value.
> - *
> - * We want to under-estimate the load of migration sources, to
> - * balance conservatively.
> - */
> -static unsigned long source_load(int cpu)
> -{
> - struct rq *rq = cpu_rq(cpu);
> - unsigned long total = weighted_cpuload(cpu);
> -
> - if (!sched_feat(LB_BIAS))
> - return total;
> -
> - return min(rq->cpu_load, total);
> -}
> -
> -/*
> - * Return a high guess at the load of a migration-target cpu weighted
> - * according to the scheduling class and "nice" value.
> - */
> -static unsigned long target_load(int cpu)
> -{
> - struct rq *rq = cpu_rq(cpu);
> - unsigned long total = weighted_cpuload(cpu);
> -
> - if (!sched_feat(LB_BIAS))
> - return total;
> -
> - return max(rq->cpu_load, total);
> -}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists