[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160614121133.GF30921@twins.programming.kicks-ass.net>
Date: Tue, 14 Jun 2016 14:11:33 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Matt Fleming <matt@...eblueprint.co.uk>
Cc: Yuyang Du <yuyang.du@...el.com>, mingo@...nel.org,
linux-kernel@...r.kernel.org, bsegall@...gle.com, pjt@...gle.com,
morten.rasmussen@....com, vincent.guittot@...aro.org,
dietmar.eggemann@....com
Subject: Re: [PATCH v5 1/5] sched/fair: Clean up attach_entity_load_avg()
On Tue, Jun 14, 2016 at 12:11:52PM +0100, Matt Fleming wrote:
> On Thu, 09 Jun, at 07:15:50AM, Yuyang Du wrote:
> > attach_entity_load_avg() is called (indirectly) from:
> >
> > - switched_to_fair(): switch between classes to fair
> > - task_move_group_fair(): move between task groups
> > - enqueue_entity_load_avg(): enqueue entity
> >
> > Only in switched_to_fair() is it possible that the task's last_update_time
> > is not 0 and therefore the task needs sched avgs update, so move the task
> > sched avgs update to switched_to_fair() only. In addition, the code is
> > refactored and code comments are updated.
> >
> > No functionality change.
> >
> > Signed-off-by: Yuyang Du <yuyang.du@...el.com>
> > ---
> > kernel/sched/fair.c | 43 ++++++++++++++++++++-----------------------
> > 1 file changed, 20 insertions(+), 23 deletions(-)
>
> Looks OK to me and makes the code easier to understand. Chasing
> ->avg.last_update_time values is tricky at the best of times.
>
> Reviewed-by: Matt Fleming <matt@...eblueprint.co.uk>
So I still wonder at the point of this patch, since the next patch
deletes this code entirely. What's the point of cleaning it up if the
next patch removes it out-right.
Powered by blists - more mailing lists