Re: [PATCH v2 2/3] sched: Cleanup SCHED_THERMAL_PRESSURE kconfig entry
From: Dietmar Eggemann <dietmar.eggemann@arm.com>
Date: 2020-07-29 08:07:35
Also in:
linux-pm, lkml
Subsystem:
arm port, arm64 port (aarch64 architecture), the rest · Maintainers:
Russell King, Catalin Marinas, Will Deacon, Linus Torvalds
On 28/07/2020 18:16, Valentin Schneider wrote:
Hi, On 27/07/20 18:45, Dietmar Eggemann wrote:quoted
On 27/07/2020 16:18, Qian Cai wrote:quoted
On Sun, Jul 12, 2020 at 05:59:16PM +0100, Valentin Schneider wrote:
[...]
I went for having SCHED_THERMAL_PRESSURE in arm64/Kconfig because of where
the discussion went in the original thread ([1] in the changelog).
One point is that selecting this option requires having the right
infrastructure in place (arch_{set, scale}_thermal_pressure() must be
redefined by the architecture), which cannot be easily expressed in Kconfig
terms. Russell's point was that this is difficult for a lambda user to make
sense of, and Vincent argued that this option should simply be selected at
architecture level, which, given the context, makes sense IMO.
We could change the arch Kconfig into
select SCHED_THERMAL_PRESSURE if CPU_FREQ_THERMAL
but that seems redundant; this dependency is already expressed in
SCHED_THERMAL_PRESSURE's definition. Is there a proper pattern to select
some Kconfig option only if all of its dependencies are met?The warning when disabling CPU_FREQ_THERMAL after make defconfig disappears, so this should be OK.
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index 939c4d6bbc2e..a677e71b3d5f 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig@@ -46,7 +46,7 @@ config ARM select EDAC_ATOMIC_SCRUB select GENERIC_ALLOCATOR select GENERIC_ARCH_TOPOLOGY if ARM_CPU_TOPOLOGY - select SCHED_THERMAL_PRESSURE if ARM_CPU_TOPOLOGY + select SCHED_THERMAL_PRESSURE if ARM_CPU_TOPOLOGY && CPU_FREQ_THERMAL select GENERIC_ATOMIC64 if CPU_V7M || CPU_V6 || !CPU_32v6K || !AEABI select GENERIC_CLOCKEVENTS_BROADCAST if SMP select GENERIC_CPU_AUTOPROBE
diff --git a/arch/arm64/Kconfig b/arch/arm64/Kconfig
index c403e6f5db86..59ae16f8b941 100644
--- a/arch/arm64/Kconfig
+++ b/arch/arm64/Kconfig@@ -192,7 +192,7 @@ config ARM64 select PCI_SYSCALL if PCI select POWER_RESET select POWER_SUPPLY - select SCHED_THERMAL_PRESSURE + select SCHED_THERMAL_PRESSURE if CPU_FREQ_THERMAL select SPARSE_IRQ select SWIOTLB select SYSCTL_EXCEPTION_TRAC
_______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel