From bc09d1dea84efaff022c09b9c5175b2a75553006 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Date: Tue, 19 Dec 2023 19:28:09 +0100 Subject: [PATCH] lib: add note about process exit message for DEBUG_STACK_USAGE MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit DEBUG_STACK_USAGE doesn't only have an influence on the output of sysrq-T and sysrq-P, it also enables a message at process exit. See check_stack_usage() in kernel/exit.c where this is implemented. Link: https://lkml.kernel.org/r/20231219182808.210284-2-u.kleine-koenig@pengutronix.de Signed-off-by: Uwe Kleine-König Cc: Douglas Anderson Cc: Geert Uytterhoeven Cc: Kees Cook Cc: Marco Elver Cc: "Paul E. McKenney" Cc: Pengutronix Kernel Team Cc: Petr Mladek Cc: Randy Dunlap Cc: Stephen Boyd Cc: Zhaoyang Huang Signed-off-by: Andrew Morton --- lib/Kconfig.debug | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug index e77873cf85c7..6cc3d29338c5 100644 --- a/lib/Kconfig.debug +++ b/lib/Kconfig.debug @@ -763,6 +763,8 @@ config DEBUG_STACK_USAGE help Enables the display of the minimum amount of free stack which each task has ever had available in the sysrq-T and sysrq-P debug output. + Also emits a message to dmesg when a process exits if that process + used more stack space than previously exiting processes. This option will slow down process creation somewhat.