Skip to contentSkip to conversation

ia64: disable SCHED_STACK_END_CHECK

PATCH In review Sergei Trofimovich 1 participant 2 messages Sep 14, 2018 – Oct 15, 2018 Library code

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ia64: disable SCHED_STACK_END_CHECK

SCHED_STACK_END_CHECK assumes stack grows in one direction. ia64 is a rare case where it is not.

As a result kernel fails at startup as:

  Kernel panic - not syncing: corrupted stack end detected inside scheduler

The error does not find a real problem: it's register backing store is written on top of canary value.

Disable SCHED_STACK_END_CHECK on ia64 as there is no good place for canary without moving initial stack address.

---
 lib/Kconfig.debug | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/Kconfig.debug +1 -1
index 4966c4fbe7f7..a097dfe38d2b 100644
@@ -1004,7 +1004,7 @@ config SCHEDSTATS
 
 config SCHED_STACK_END_CHECK
 	bool "Detect stack corruption on calls to schedule()"
-	depends on DEBUG_KERNEL
+	depends on DEBUG_KERNEL && !IA64
 	default n
 	help
 	  This option checks for a stack overrun on calls to schedule().
Signature · 1 line
2.19.0
#1 lore raw
Quoted 38 lines · On Fri, 14 Sep 2018 08:06:17 +0100 Sergei Trofimovich <[email protected]> wrote:

SCHED_STACK_END_CHECK assumes stack grows in one direction. ia64 is a rare case where it is not.

As a result kernel fails at startup as:

  Kernel panic - not syncing: corrupted stack end detected inside scheduler

The error does not find a real problem: it's register backing store is written on top of canary value.

Disable SCHED_STACK_END_CHECK on ia64 as there is no good place for canary without moving initial stack address.

---
 lib/Kconfig.debug | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
lib/Kconfig.debug +1 -1
index 4966c4fbe7f7..a097dfe38d2b 100644
@@ -1004,7 +1004,7 @@ config SCHEDSTATS
 
 config SCHED_STACK_END_CHECK
 	bool "Detect stack corruption on calls to schedule()"
-	depends on DEBUG_KERNEL
+	depends on DEBUG_KERNEL && !IA64
 	default n
 	help
 	  This option checks for a stack overrun on calls to schedule().
Signature · 1 line
2.19.0

Ping.

Signature · 1 line
  Sergei