From: Arjan van de Ven <arjan@linux.intel.com>
To: Ai Li <aili@codeaurora.org>
Cc: akpm@linux-foundation.org, dwalker@codeaurora.org, mingo@elte.hu,
shemminger@vyatta.com, czoccolo@gmail.com, len.brown@intel.com,
linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org,
linux-pm@lists.linux-foundation.org
Subject: Re: [PATCH] cpuidle: extend cpuidle and menu governor to handle dynamic states
Date: Thu, 15 Jul 2010 21:07:13 -0700 [thread overview]
Message-ID: <4C3FDAF1.7030107@linux.intel.com> (raw)
In-Reply-To: <1279225825-31069-1-git-send-email-aili@codeaurora.org>
On 7/15/2010 1:30 PM, Ai Li wrote:
I'm ok with the general idea, but have a few comments about the
implementation
> Signed-off-by: Ai Li<aili@codeaurora.org>
> ---
> drivers/cpuidle/governors/menu.c | 59 +++++++++++++++++++++++++++++--------
> include/linux/cpuidle.h | 4 ++
> 2 files changed, 50 insertions(+), 13 deletions(-)
>
> diff --git a/drivers/cpuidle/governors/menu.c b/drivers/cpuidle/governors/menu.c
> index 1b12870..b3854cc 100644
> --- a/drivers/cpuidle/governors/menu.c
> +++ b/drivers/cpuidle/governors/menu.c
> @@ -271,6 +271,9 @@ static int menu_select(struct cpuidle_device *dev)
>
> detect_repeating_patterns(data);
>
> + if (dev->prepare)
> + dev->prepare(dev, data->predicted_us);
>
I don't like the idea of passing predicted_us here.
the states and their updates should be independent of how long we think
we'll be idle;
it's up to the menu governor to then pick a good one, not for the
platform to muck with things
based on this.
Also I would like the cpuidle code, not the governor, to call this
prepare function.
The need to call ->prepare is governor independent....
+ if (dev->compare_power) {
I'm not a big fan of this as a flag; either we always do this, which I
can understand, or we sort things, which is also fine with me.
Doing this condition like this.... not a fan.
next prev parent reply other threads:[~2010-07-16 4:07 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-07-15 20:30 [PATCH] cpuidle: extend cpuidle and menu governor to handle dynamic states Ai Li
2010-07-16 4:07 ` Arjan van de Ven
2010-07-16 4:07 ` Arjan van de Ven [this message]
2010-07-16 17:25 ` Ai Li
2010-07-16 17:25 ` Ai Li
2010-07-16 17:25 ` Ai Li
2010-07-16 17:28 ` Arjan van de Ven
2010-07-16 19:19 ` Ai Li
2010-07-16 19:19 ` Ai Li
2010-07-16 19:33 ` Arjan van de Ven
2010-07-16 19:33 ` Arjan van de Ven
2010-07-16 19:52 ` Ai Li
2010-07-16 19:52 ` Ai Li
2010-07-16 19:52 ` Ai Li
2010-07-16 19:19 ` Ai Li
2010-07-16 17:28 ` Arjan van de Ven
-- strict thread matches above, loose matches on Subject: below --
2010-07-15 20:30 Ai Li
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=4C3FDAF1.7030107@linux.intel.com \
--to=arjan@linux.intel.com \
--cc=aili@codeaurora.org \
--cc=akpm@linux-foundation.org \
--cc=czoccolo@gmail.com \
--cc=dwalker@codeaurora.org \
--cc=len.brown@intel.com \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@lists.linux-foundation.org \
--cc=mingo@elte.hu \
--cc=shemminger@vyatta.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.