public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
From: Kevin Hilman <khilman@ti.com>
To: Rajendra Nayak <rnayak@ti.com>
Cc: linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH] OMAP2+: PM: Warn users of sleep_while_idle if !CONFIG_CPU_IDLE
Date: Tue, 01 Mar 2011 13:54:17 -0800	[thread overview]
Message-ID: <87sjv6h5h2.fsf@ti.com> (raw)
In-Reply-To: <1297857860-3713-1-git-send-email-rnayak@ti.com> (Rajendra Nayak's message of "Wed, 16 Feb 2011 17:34:20 +0530")

Rajendra Nayak <rnayak@ti.com> writes:

> This should help users who do a
> 'echo 1 > /debug/pm_debug/sleep_while_idle' with a
> config which has !CONFIG_CPU_IDLE and wonder
> why OMAP is'nt sleeping in idle.

This isn't quite right, as 'sleep_while_idle' is actually a flag for
whether or not to call omap_sram_idle() at all.

Even without CPUidle, WFI will still be attempted.

Kevin

> Signed-off-by: Rajendra Nayak <rnayak@ti.com>
> ---
>  arch/arm/mach-omap2/pm-debug.c |    9 +++++++++
>  1 files changed, 9 insertions(+), 0 deletions(-)
>
> diff --git a/arch/arm/mach-omap2/pm-debug.c b/arch/arm/mach-omap2/pm-debug.c
> index 125f565..1e722a0 100644
> --- a/arch/arm/mach-omap2/pm-debug.c
> +++ b/arch/arm/mach-omap2/pm-debug.c
> @@ -569,6 +569,10 @@ static int option_get(void *data, u64 *val)
>  
>  	*val = *option;
>  
> +#ifndef CONFIG_CPU_IDLE
> +	if (option == &sleep_while_idle)
> +		pr_warn("CONFIG_CPU_IDLE is not enabled\n");
> +#endif
>  	return 0;
>  }
>  
> @@ -581,6 +585,11 @@ static int option_set(void *data, u64 val)
>  
>  	*option = val;
>  
> +#ifndef CONFIG_CPU_IDLE
> +	if (option == &sleep_while_idle)
> +		pr_warn("CONFIG_CPU_IDLE is not enabled\n");
> +#endif
> +
>  	if (option == &enable_off_mode) {
>  		if (val)
>  			omap_pm_enable_off_mode();

  reply	other threads:[~2011-03-01 21:54 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-16 12:04 [PATCH] OMAP2+: PM: Warn users of sleep_while_idle if !CONFIG_CPU_IDLE Rajendra Nayak
2011-03-01 21:54 ` Kevin Hilman [this message]
2011-03-03  9:32   ` Rajendra Nayak

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=87sjv6h5h2.fsf@ti.com \
    --to=khilman@ti.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-omap@vger.kernel.org \
    --cc=rnayak@ti.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox