From: Vaidyanathan Srinivasan <svaidy@linux.ibm.com>
To: Vishal Chourasia <vishalc@linux.vnet.ibm.com>
Cc: srikar@linux.vnet.ibm.com, linux-pm@vger.kernel.org,
Aboorva Devarajan <aboorvad@linux.vnet.ibm.com>,
daniel.lezcano@linaro.org, npiggin@gmail.com, rafael@kernel.org,
linuxppc-dev@lists.ozlabs.org
Subject: Re: [PATCH v2] powerpc/cpuidle: Set CPUIDLE_FLAG_POLLING for snooze state
Date: Fri, 2 Dec 2022 16:47:41 +0530 [thread overview]
Message-ID: <Y4ne1Yzab02YHlxn@drishya.in.ibm.com> (raw)
In-Reply-To: <Y3iYsI8FFkwTFfPO@li-05afa54c-330e-11b2-a85c-e3f3aa0db1e9.ibm.com>
* Vishal Chourasia <vishalc@linux.vnet.ibm.com> [2022-11-19 14:19:52]:
> On Mon, Nov 14, 2022 at 08:26:11PM +0530, Aboorva Devarajan wrote:
> > During the comparative study of cpuidle governors, it is noticed that the
> > menu governor does not select CEDE state in some scenarios even though when
> > the sleep duration of the CPU exceeds the target residency of the CEDE idle
> > state this is because the CPU exits the snooze "polling" state when snooze
> > time limit is reached in the snooze_loop(), which is not a real wake up
> > and it just means that the polling state selection was not adequate.
> >
> > cpuidle governors rely on CPUIDLE_FLAG_POLLING flag to be set for the
> > polling states to handle the condition mentioned above.
> >
> > Hence, set the CPUIDLE_FLAG_POLLING flag for snooze state (polling state)
> > in powerpc arch to make the cpuidle governor work as expected.
> >
> > Reference Commits:
> >
> > - Timeout enabled for snooze state:
> > commit 78eaa10f027c
> > ("cpuidle: powernv/pseries: Auto-promotion of snooze to deeper idle state")
> >
> > - commit dc2251bf98c6
> > ("cpuidle: Eliminate the CPUIDLE_DRIVER_STATE_START symbol")
> >
> > - Fix wakeup stats in governor for polling states
> > commit 5f26bdceb9c0
> > ("cpuidle: menu: Fix wakeup statistics updates for polling state")
> >
> > Signed-off-by: Aboorva Devarajan <aboorvad@linux.vnet.ibm.com>
> > ---
> >
> > Changelog: (v1 -> v2)
> >
> > Added CPUIDLE_POLLING_FLAG to the correct cpuidle_state struct.
> >
> > Previous version of the patch is stale which was sent by mistake, this
> > is the correct version which is tested on powernv, pseries (shared and
> > dedicated partitions)
> >
> > drivers/cpuidle/cpuidle-powernv.c | 5 ++++-
> > drivers/cpuidle/cpuidle-pseries.c | 8 ++++++--
> > 2 files changed, 10 insertions(+), 3 deletions(-)
Hi Aboorva,
Thanks for the patch. This fixes the unpredictable idle state
selection issue under differ idle interval patterns.
Reviewed-by: Vaidyanathan Srinivasan <svaidy@linux.ibm.com>
--Vaidy
next prev parent reply other threads:[~2022-12-02 23:06 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-14 7:31 [PATCH] powerpc/cpuidle: Set CPUIDLE_FLAG_POLLING for snooze state Aboorva Devarajan
2022-11-14 14:56 ` [PATCH v2] " Aboorva Devarajan
2022-11-19 8:49 ` Vishal Chourasia
2022-12-02 11:17 ` Vaidyanathan Srinivasan [this message]
2022-12-08 12:40 ` Michael Ellerman
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=Y4ne1Yzab02YHlxn@drishya.in.ibm.com \
--to=svaidy@linux.ibm.com \
--cc=aboorvad@linux.vnet.ibm.com \
--cc=daniel.lezcano@linaro.org \
--cc=linux-pm@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=npiggin@gmail.com \
--cc=rafael@kernel.org \
--cc=srikar@linux.vnet.ibm.com \
--cc=vishalc@linux.vnet.ibm.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;
as well as URLs for NNTP newsgroup(s).