LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
To: "Rafael J. Wysocki" <rjw@rjwysocki.net>
Cc: Daniel Lezcano <daniel.lezcano@linaro.org>,
	"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Peter Zijlstra <peterz@infradead.org>,
	"preeti@linux.vnet.ibm.com" <preeti@linux.vnet.ibm.com>
Subject: Re: [PATCH 2/2] cpuidle / sleep: Use broadcast timer for states that stop local timer
Date: Mon, 2 Mar 2015 16:27:06 +0000	[thread overview]
Message-ID: <20150302162706.GB5515@red-moon> (raw)
In-Reply-To: <89103967.z1sWWFaE6y@vostro.rjw.lan>

On Mon, Mar 02, 2015 at 02:53:28PM +0000, Rafael J. Wysocki wrote:
> From: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> 
> Commit 381063133246 (PM / sleep: Re-implement suspend-to-idle handling)
> overlooked the fact that entering some sufficiently deep idle states
> by CPUs may cause their local timers to stop and in those cases it
> is necessary to switch over to a broadcase timer prior to entering

s/broadcase/broadcast

> the idle state.  If the cpuidle driver in use does not provide
> the new ->enter_freeze callback for any of the idle states, that
> problem affects suspend-to-idle too, but it is not taken into account
> after the changes made by commit 381063133246.
> 
> Fix that by changing the definition of cpuidle_enter_freeze() and
> re-arranging of the code in cpuidle_idle_call(), so the former does
> not call cpuidle_enter() any more and the fallback case is handled
> by cpuidle_idle_call() directly.
> 
> Fixes: 381063133246 (PM / sleep: Re-implement suspend-to-idle handling)
> Reported-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>

Minor comment below, otherwise on the 4-patch series:

Tested-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>

[...]

>  /**
>   * cpuidle_enter_freeze - Enter an idle state suitable for suspend-to-idle.
> + * @drv: cpuidle driver for the given CPU.
> + * @dev: cpuidle device for the given CPU.
>   *
>   * If there are states with the ->enter_freeze callback, find the deepest of
>   * them and enter it with frozen tick.  Otherwise, find the deepest state
>   * available and enter it normally.

Comment above becomes stale so you should update it, other than that it
seems fine.

Thanks,
Lorenzo

  reply	other threads:[~2015-03-02 16:27 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-24 17:58 [PATCH 0/2] drivers: cpuidle: minor suspend-to-idle fixes Lorenzo Pieralisi
2015-02-24 17:58 ` [PATCH 1/2] drivers: cpuidle: remove stale irq disabling call in cpuidle_enter_freeze() Lorenzo Pieralisi
2015-02-25 14:13   ` Daniel Lezcano
2015-02-25 14:39     ` Lorenzo Pieralisi
2015-02-25 23:36       ` Rafael J. Wysocki
2015-02-26  9:48         ` Lorenzo Pieralisi
2015-02-26 16:39           ` Rafael J. Wysocki
2015-02-24 17:58 ` [PATCH 2/2] drivers: cpuidle: add driver/device checks " Lorenzo Pieralisi
2015-02-25 14:30   ` Daniel Lezcano
2015-02-25 14:47     ` Lorenzo Pieralisi
2015-02-25 23:50       ` Rafael J. Wysocki
2015-02-26  0:35         ` Rafael J. Wysocki
2015-02-25 14:56     ` Lorenzo Pieralisi
2015-02-26 23:37 ` [PATCH 0/2] drivers: cpuidle: minor suspend-to-idle fixes Rafael J. Wysocki
2015-02-26 23:39   ` [PATCH 1/2] idle / sleep: Avoid excessive interrupts disabling and enabling Rafael J. Wysocki
2015-02-26 23:39   ` [PATCH 2/2] cpuidle / sleep: Do sanity checks in cpuidle_enter_freeze() too Rafael J. Wysocki
2015-02-27  8:41   ` [PATCH 0/2] drivers: cpuidle: minor suspend-to-idle fixes Peter Zijlstra
2015-02-27 10:00   ` Lorenzo Pieralisi
2015-02-27 22:11     ` Rafael J. Wysocki
2015-02-28 11:54       ` Lorenzo Pieralisi
2015-02-28 23:58         ` Rafael J. Wysocki
2015-03-02 10:08           ` Lorenzo Pieralisi
2015-03-02 13:13             ` Rafael J. Wysocki
2015-03-02 14:50               ` [PATCH 0/2] cpuidle / sleep: fix timer stopping regression (was: drivers: cpuidle: minor suspend-to-idle fixes) Rafael J. Wysocki
2015-03-02 14:51                 ` [PATCH 1/2] cpuidle: Clean up fallback handling in cpuidle_idle_call() Rafael J. Wysocki
2015-03-02 16:05                   ` Lorenzo Pieralisi
2015-03-02 22:30                     ` Rafael J. Wysocki
2015-03-02 14:53                 ` [PATCH 2/2] cpuidle / sleep: Use broadcast timer for states that stop local timer Rafael J. Wysocki
2015-03-02 16:27                   ` Lorenzo Pieralisi [this message]
2015-03-02 22:28                     ` Rafael J. Wysocki

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=20150302162706.GB5515@red-moon \
    --to=lorenzo.pieralisi@arm.com \
    --cc=daniel.lezcano@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=peterz@infradead.org \
    --cc=preeti@linux.vnet.ibm.com \
    --cc=rjw@rjwysocki.net \
    --subject='Re: [PATCH 2/2] cpuidle / sleep: Use broadcast timer for states that stop local timer' \
    /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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).