Skip to contentSkip to conversation

sched/isolation: Make CPU_ISOLATION depend on SMP or COMPILE_TEST

PATCH In review Geert Uytterhoeven 3 participants 3 messages Jan 2, 2018 – Jan 8, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 sched/isolation: Make CPU_ISOLATION depend on SMP or COMPILE_TEST

On uniprocessor systems, critical and non-critical tasks cannot be isolated, as there is only a single CPU core. Hence enabling CPU isolation by default on such systems does not make much sense.

Instead of changing the default for !SMP, fix this by making the feature depend on SMP, with an override for compile-testing. Note that its sole selector (NO_HZ_FULL) already depends on SMP.

This decreases kernel size for a default uniprocessor kernel by ca. 1 KiB.

Fixes 2c43838c99d9d23f ("sched/isolation: Enable CONFIG_CPU_ISOLATION=y by default")
---
 init/Kconfig | 1 +
 1 file changed, 1 insertion(+)
init/Kconfig +1 -0
index 690a381adee0d164..c1221332e128c700 100644
@@ -461,6 +461,7 @@ endmenu # "CPU/Task time and stats accounting"
 
 config CPU_ISOLATION
 	bool "CPU isolation"
+	depends on SMP || COMPILE_TEST
 	default y
 	help
 	  Make sure that CPUs running critical tasks are not disturbed by
Signature · 1 line
2.7.4
Acked-by on v1 1/1
#1 lore raw
Quoted 8 lines · Geert Uytterhoeven

On uniprocessor systems, critical and non-critical tasks cannot be isolated, as there is only a single CPU core. Hence enabling CPU isolation by default on such systems does not make much sense.

Instead of changing the default for !SMP, fix this by making the feature depend on SMP, with an override for compile-testing. Note that its sole selector (NO_HZ_FULL) already depends on SMP.

Quoted 5 lines

This decreases kernel size for a default uniprocessor kernel by ca. 1 KiB.

Fixes 2c43838c99d9d23f ("sched/isolation: Enable CONFIG_CPU_ISOLATION=y by default")
Quoted 20 lines
---
 init/Kconfig | 1 +
 1 file changed, 1 insertion(+)
init/Kconfig +1 -0
index 690a381adee0d164..c1221332e128c700 100644
@@ -461,6 +461,7 @@ endmenu # "CPU/Task time and stats accounting"
 
 config CPU_ISOLATION
 	bool "CPU isolation"
+	depends on SMP || COMPILE_TEST
 	default y
 	help
 	  Make sure that CPUs running critical tasks are not disturbed by
Signature · 1 line
2.7.4
#2 lore raw

[tip:sched/urgent] sched/isolation: Make CONFIG_CPU_ISOLATION=y depend on SMP or COMPILE_TEST

In reply to Geert Uytterhoeven
sched/isolation: Make CONFIG_CPU_ISOLATION=y depend on SMP or COMPILE_TEST
Commit-ID:  414a2dc138838642d28938506e31ad461648b898
Gitweb:     https://git.kernel.org/tip/414a2dc138838642d28938506e31ad461648b898
Author:     Geert Uytterhoeven <[email protected]>
AuthorDate: Tue, 2 Jan 2018 12:13:10 +0100
Committer:  Ingo Molnar <[email protected]>
CommitDate: Mon, 8 Jan 2018 20:04:07 +0100

sched/isolation: Make CONFIG_CPU_ISOLATION=y depend on SMP or COMPILE_TEST

On uniprocessor systems, critical and non-critical tasks cannot be isolated, as there is only a single CPU core. Hence enabling CPU isolation by default on such systems does not make much sense.

Instead of changing the default for !SMP, fix this by making the feature depend on SMP, with an override for compile-testing. Note that its sole selector (NO_HZ_FULL) already depends on SMP.

This decreases kernel size for a default uniprocessor kernel by ca. 1 KiB.

Cc Frederic Weisbecker <[email protected]>
Cc Linus Torvalds <[email protected]>
Cc Peter Zijlstra <[email protected]>
Cc Thomas Gleixner <[email protected]>
Fixes 2c43838c99d9d23f ("sched/isolation: Enable CONFIG_CPU_ISOLATION=y by default")
---
 init/Kconfig | 1 +
 1 file changed, 1 insertion(+)
init/Kconfig +1 -0
index 690a381..c122133 100644
@@ -461,6 +461,7 @@ endmenu # "CPU/Task time and stats accounting"
 
 config CPU_ISOLATION
 	bool "CPU isolation"
+	depends on SMP || COMPILE_TEST
 	default y
 	help
 	  Make sure that CPUs running critical tasks are not disturbed by