From: Dietmar Eggemann <dietmar.eggemann@arm.com>
To: Qian Cai <cai@lca.pw>, Valentin Schneider <valentin.schneider@arm.com>
Cc: Juri Lelli <juri.lelli@redhat.com>,
Vincent Guittot <vincent.guittot@linaro.org>,
linux-pm@vger.kernel.org, Peter Zijlstra <peterz@infradead.org>,
Viresh Kumar <viresh.kumar@linaro.org>,
Amit Daniel Kachhap <amit.kachhap@gmail.com>,
Daniel Lezcano <daniel.lezcano@linaro.org>,
Russell King <linux@armlinux.org.uk>,
Thara Gopinath <thara.gopinath@linaro.org>,
linux-kernel@vger.kernel.org, Sudeep Holla <sudeep.holla@arm.com>,
Ingo Molnar <mingo@kernel.org>,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v2 2/3] sched: Cleanup SCHED_THERMAL_PRESSURE kconfig entry
Date: Mon, 27 Jul 2020 19:45:49 +0200 [thread overview]
Message-ID: <16f8c1d4-778b-3ab8-f328-bae80f3973b4@arm.com> (raw)
In-Reply-To: <20200727141825.GA4174@lca.pw>
On 27/07/2020 16:18, Qian Cai wrote:
> On Sun, Jul 12, 2020 at 05:59:16PM +0100, Valentin Schneider wrote:
>> As Russell pointed out [1], this option is severely lacking in the
>> documentation department, and figuring out if one has the required
>> dependencies to benefit from turning it on is not straightforward.
>>
>> Make it non user-visible, and add a bit of help to it. While at it, make it
>> depend on CPU_FREQ_THERMAL.
>>
>> [1]: https://lkml.kernel.org/r/20200603173150.GB1551@shell.armlinux.org.uk
>>
>> Signed-off-by: Valentin Schneider <valentin.schneider@arm.com>
>> ---
>> init/Kconfig | 15 ++++++++++++++-
>> 1 file changed, 14 insertions(+), 1 deletion(-)
>>
>> diff --git a/init/Kconfig b/init/Kconfig
>> index 0498af567f70..0a97d85568b2 100644
>> --- a/init/Kconfig
>> +++ b/init/Kconfig
>> @@ -492,8 +492,21 @@ config HAVE_SCHED_AVG_IRQ
>> depends on SMP
>>
>> config SCHED_THERMAL_PRESSURE
>> - bool "Enable periodic averaging of thermal pressure"
>> + bool
>> depends on SMP
>> + depends on CPU_FREQ_THERMAL
>> + help
>> + Select this option to enable thermal pressure accounting in the
>> + scheduler. Thermal pressure is the value conveyed to the scheduler
>> + that reflects the reduction in CPU compute capacity resulted from
>> + thermal throttling. Thermal throttling occurs when the performance of
>> + a CPU is capped due to high operating temperatures.
>> +
>> + If selected, the scheduler will be able to balance tasks accordingly,
>> + i.e. put less load on throttled CPUs than on non/less throttled ones.
>> +
>> + This requires the architecture to implement
>> + arch_set_thermal_pressure() and arch_get_thermal_pressure().
>>
>> config BSD_PROCESS_ACCT
>> bool "BSD Process Accounting"
>> --
>
> On arm64 linux-next (20200727),
>
> https://gitlab.com/cailca/linux-mm/-/blob/master/arm64.config
>
> WARNING: unmet direct dependencies detected for SCHED_THERMAL_PRESSURE
> Depends on [n]: SMP [=y] && CPU_FREQ_THERMAL [=n]
> Selected by [y]:
> - ARM64 [=y]
Not sure, but:
(1) do we wan to let people enable SCHED_THERMAL_PRESSURE for arm64 so
arm64 can potentially run w/o a CPU freq cooling device?
diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig
index 2d4abbc9f8d0..baffe8b66da2 100644
--- a/arch/arm64/Kconfig
+++ b/arch/arm64/Kconfig
@@ -192,7 +192,6 @@ config ARM64
select PCI_SYSCALL if PCI
select POWER_RESET
select POWER_SUPPLY
- select SCHED_THERMAL_PRESSURE
select SPARSE_IRQ
select SWIOTLB
select SYSCTL_EXCEPTION_TRACE
diff --git a/init/Kconfig b/init/Kconfig
index 37b089f87804..8b36e07fb230 100644
--- a/init/Kconfig
+++ b/init/Kconfig
@@ -492,7 +492,7 @@ config HAVE_SCHED_AVG_IRQ
depends on SMP
config SCHED_THERMAL_PRESSURE
- bool
+ bool "Thermal pressure accounting"
depends on SMP
depends on CPU_FREQ_THERMAL
help
Or
(2) should SCHED_THERMAL_PRESSURE for arm64 be enabled by default?
But then it makes no sense to allow the removal of CONFIG_CPU_FREQ_THERMAL.
linux-next/master$ make ARCH=arm64 defconfig
// Remove CONFIG_CPU_FREQ_THERMAL
linux-next/master$ grep CPU_FREQ_THERMAL .config
# CONFIG_CPU_FREQ_THERMAL is not set
linux-next/master$ make
scripts/kconfig/conf --syncconfig Kconfig
WARNING: unmet direct dependencies detected for SCHED_THERMAL_PRESSURE
Depends on [n]: SMP [=y] && CPU_FREQ_THERMAL [=n]
Selected by [y]:
- ARM64 [=y]
WARNING: unmet direct dependencies detected for SCHED_THERMAL_PRESSURE
Depends on [n]: SMP [=y] && CPU_FREQ_THERMAL [=n]
Selected by [y]:
- ARM64 [=y]
WARNING: unmet direct dependencies detected for SCHED_THERMAL_PRESSURE
Depends on [n]: SMP [=y] && CPU_FREQ_THERMAL [=n]
Selected by [y]:
- ARM64 [=y]
HOSTCC scripts/dtc/dtc.o
---
There is a similar issue with arm.
I would prefer for (1).
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2020-07-27 17:47 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-12 16:59 [PATCH v2 0/3] sched, arch_topology: Thermal pressure configuration cleanup Valentin Schneider
2020-07-12 16:59 ` [PATCH v2 1/3] arch_topology, sched/core: Cleanup thermal pressure definition Valentin Schneider
2020-07-13 14:32 ` Thara Gopinath
2020-07-12 16:59 ` [PATCH v2 2/3] sched: Cleanup SCHED_THERMAL_PRESSURE kconfig entry Valentin Schneider
2020-07-27 14:18 ` Qian Cai
2020-07-27 17:45 ` Dietmar Eggemann [this message]
2020-07-28 16:16 ` Valentin Schneider
2020-07-29 8:07 ` Dietmar Eggemann
2020-07-29 13:09 ` Quentin Perret
2020-07-29 13:29 ` Valentin Schneider
2020-07-12 16:59 ` [PATCH v2 3/3] arm, arm64: Select CONFIG_SCHED_THERMAL_PRESSURE Valentin Schneider
2020-07-13 10:03 ` Catalin Marinas
2020-07-13 10:29 ` Valentin Schneider
2020-07-13 10:37 ` [PATCH v2 0/3] sched, arch_topology: Thermal pressure configuration cleanup Peter Zijlstra
2020-07-13 12:03 ` Vincent Guittot
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=16f8c1d4-778b-3ab8-f328-bae80f3973b4@arm.com \
--to=dietmar.eggemann@arm.com \
--cc=amit.kachhap@gmail.com \
--cc=cai@lca.pw \
--cc=daniel.lezcano@linaro.org \
--cc=juri.lelli@redhat.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=mingo@kernel.org \
--cc=peterz@infradead.org \
--cc=sudeep.holla@arm.com \
--cc=thara.gopinath@linaro.org \
--cc=valentin.schneider@arm.com \
--cc=vincent.guittot@linaro.org \
--cc=viresh.kumar@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;
as well as URLs for NNTP newsgroup(s).