Linux Power Management development
 help / color / mirror / Atom feed
From: Viresh Kumar <viresh.kumar@linaro.org>
To: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: Leonard Crestez <leonard.crestez@nxp.com>,
	Linux PM <linux-pm@vger.kernel.org>,
	Anson Huang <anson.huang@nxp.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	Patrick Bellasi <patrick.bellasi@arm.com>,
	Juri Lelli <juri.lelli@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	vincent.guittot@linaro.org
Subject: Re: [BUG] schedutil governor produces regular max freq spikes because of lockup detector watchdog threads
Date: Mon, 8 Jan 2018 09:31:21 +0530	[thread overview]
Message-ID: <20180108040121.GB4003@vireshk-i7> (raw)
In-Reply-To: <CAJZ5v0gOwgr2yB_YY8ian6GXjdic3zRUa4S9vHNmudC8Khc5cA@mail.gmail.com>

On 05-01-18, 23:18, Rafael J. Wysocki wrote:
> On Fri, Jan 5, 2018 at 9:37 PM, Leonard Crestez <leonard.crestez@nxp.com> wrote:
> > Hello,
> >
> > When using the schedutil governor together with the softlockup detector
> > all CPUs go to their maximum frequency on a regular basis. This seems
> > to be because the watchdog creates a RT thread on each CPU and this
> > causes regular kicks with:
> >
> >     cpufreq_update_this_cpu(rq, SCHED_CPUFREQ_RT);
> >
> > The schedutil governor responds to this by immediately setting the
> > maximum cpu frequency, this is very undesirable.
> >
> > The issue can be fixed by this patch from android:
> >     https://patchwork.kernel.org/patch/9301909/
> >
> > The patch stalled in a long discussion about how it's difficult for
> > cpufreq to deal with RT and how some RT users might just disable
> > cpufreq. It is indeed hard but if the system experiences regular power
> > kicks from a common debug feature they will end up disabling schedutil
> > instead.
> 
> They are basically free to use the other governors instead if they prefer them.
> 
> > No other governors behave this way,
> 
> Because they work differently overall.
> 
> > perhaps the current behavior should be considered a bug in schedutil.
> >
> > That patch now has conflicts with latest upstream. Perhaps a modified
> > variant should be reconsidered for inclusion, or is there some other
> > solution pending?
> 
> Patrick has a series of patches dealing with this problem area AFAICS,
> but we are currently integrating material from Juri related to
> deadline tasks.

I am not sure if Patrick's patches would solve this problem at all as
we still go to max for RT and the RT task is created from the
softlockup detector somehow.

One way to fix that can be to use DL for the softlockup detector as
after Juri's patches we don't always go to max for DL.

On the other side, AFAIR, Peter was very clear during the previous LPC
that it doesn't make sense to use rt-avg as the above patch suggests.

-- 
viresh

  reply	other threads:[~2018-01-08  4:01 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-05 20:37 [BUG] schedutil governor produces regular max freq spikes because of lockup detector watchdog threads Leonard Crestez
2018-01-05 22:18 ` Rafael J. Wysocki
2018-01-08  4:01   ` Viresh Kumar [this message]
2018-01-08 13:10     ` Rafael J. Wysocki
2018-01-08 13:20     ` Leonard Crestez
2018-01-08 15:14       ` Patrick Bellasi
2018-01-08 15:51         ` Leonard Crestez
2018-01-09  1:17           ` Rafael J. Wysocki
2018-01-09 14:43             ` Leonard Crestez
2018-01-09 15:16               ` Lucas Stach
2018-01-09 15:50               ` Rafael J. Wysocki
2018-01-10 10:54                 ` Juri Lelli
2018-01-10 12:35                   ` Rafael J. Wysocki
2018-01-10 14:21                     ` Juri Lelli
2018-01-11  1:20                       ` Rafael J. Wysocki
2018-01-10  4:08               ` Viresh Kumar
  -- strict thread matches above, loose matches on Subject: below --
2018-01-06 16:12 Doug Smythies

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=20180108040121.GB4003@vireshk-i7 \
    --to=viresh.kumar@linaro.org \
    --cc=anson.huang@nxp.com \
    --cc=juri.lelli@redhat.com \
    --cc=leonard.crestez@nxp.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=patrick.bellasi@arm.com \
    --cc=peterz@infradead.org \
    --cc=rafael@kernel.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