From: Peter Zijlstra <peterz@infradead.org>
To: Vincent Guittot <vincent.guittot@linaro.org>
Cc: linux-kernel <linux-kernel@vger.kernel.org>,
"linaro-kernel@lists.linaro.org" <linaro-kernel@lists.linaro.org>,
"Ingo Molnar" <mingo@kernel.org>, "Paul Turner" <pjt@google.com>,
"Steven Rostedt" <rostedt@goodmis.org>,
"Frédéric Weisbecker" <fweisbec@gmail.com>,
"Mike Galbraith" <efault@gmx.de>
Subject: Re: [PATCH v4] sched: fix wrong rq's runnable_avg update with rt tasks
Date: Wed, 10 Apr 2013 09:26:54 +0200 [thread overview]
Message-ID: <1365578814.30071.19.camel@laptop> (raw)
In-Reply-To: <CAKfTPtDJa5Am+jEHSzy+hhh+9=GcR9YXzKV-DAH3D3Hq6uMHog@mail.gmail.com>
On Tue, 2013-04-09 at 11:06 +0200, Vincent Guittot wrote:
> >> +void idle_enter(struct rq *this_rq)
> >> +{
> >> + update_rq_runnable_avg(this_rq, 1);
> >> +}
> >> +void idle_exit(struct rq *this_rq)
> >> +{
> >> + update_rq_runnable_avg(this_rq, 0);
> >> +}
> >
> > These seem like fairly unfortunate names to expose to the global
> > namespace, why not expose update_rq_runnable_avg() instead?
>
> Just to gather in one place all cfs actions that should be done when
> exiting idle even if we only have update_rq_runnable_avg right now. I
> have distinguished that from idle_balance because this sequence can't
> generate extra context switch like idle_balance and they would finally
> not be called in the same time
OK, but could we then please give then more scheduler specific names?
It just seems to me that idle_enter/idle_exit() are very obvious
function names for unrelated things.
How about calling it idle_{enter,exit}_fair; so that once other classes
grow hooks we can do something like:
static void pre_schedule_idle(struct rq *rq, struct task_struct *p)
{
struct sched_class *class;
for_each_class(class) {
if (class->idle_enter)
class->idle_enter(rq);
}
}
or whatnot..
next prev parent reply other threads:[~2013-04-10 7:27 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-04 14:15 Vincent Guittot
2013-04-09 8:50 ` Peter Zijlstra
2013-04-09 9:06 ` Vincent Guittot
2013-04-10 7:26 ` Peter Zijlstra [this message]
2013-04-10 7:59 ` Vincent Guittot
2013-04-09 8:55 ` Peter Zijlstra
2013-04-09 12:18 ` Vincent Guittot
2013-04-09 13:16 ` Steven Rostedt
2013-04-09 14:05 ` Vincent Guittot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1365578814.30071.19.camel@laptop \
--to=peterz@infradead.org \
--cc=efault@gmx.de \
--cc=fweisbec@gmail.com \
--cc=linaro-kernel@lists.linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=pjt@google.com \
--cc=rostedt@goodmis.org \
--cc=vincent.guittot@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome