Skip to contentSkip to conversation

Kconfig.debug: provide a little extra FRAME_WARN leeway when KASAN is enabled

PATCH New Lee Jones 1 participant 1 message Dec 6, 2022

Subsystems (2)
lore
Share & tools
lore

Lee Jones

author
#0 lore raw

PATCH 1/1 Kconfig.debug: provide a little extra FRAME_WARN leeway when KASAN is enabled

commit 152fe65f300e1819d59b80477d3e0999b4d5d7d2 upstream.

When enabled, KASAN enlarges function's stack-frames. Pushing quite a few over the current threshold. This can mainly be seen on 32-bit architectures where the present limit (when !GCC) is a lowly 1024-Bytes.

Cc Alex Deucher <[email protected]>
Cc "Christian König" <[email protected]>
Cc Daniel Vetter <[email protected]>
Cc David Airlie <[email protected]>
Cc Harry Wentland <[email protected]>
Cc Leo Li <[email protected]>
Cc Maarten Lankhorst <[email protected]>
Cc Maxime Ripard <[email protected]>
Cc Nathan Chancellor <[email protected]>
Cc Nick Desaulniers <[email protected]>
Cc "Pan, Xinhui" <[email protected]>
Cc Rodrigo Siqueira <[email protected]>
Cc Thomas Zimmermann <[email protected]>
Cc Tom Rix <[email protected]>
[Lee: Back-ported to linux-5.10.y]
---
 lib/Kconfig.debug | 1 +
 1 file changed, 1 insertion(+)
lib/Kconfig.debug +1 -0
index ce796ca869c22..ea0628a0116d0 100644
@@ -298,6 +298,7 @@ config FRAME_WARN
 	int "Warn for stack frames larger than"
 	range 0 8192
 	default 2048 if GCC_PLUGIN_LATENT_ENTROPY
+	default 1280 if KASAN && !64BIT
 	default 1280 if (!64BIT && PARISC)
 	default 1024 if (!64BIT && !PARISC)
 	default 2048 if 64BIT
Signature · 1 line
2.39.0.rc0.267.gcb52ba06e7-goog