From 413b1cf4091c0aab3a03d9a0fd032cea0af5248c Mon Sep 17 00:00:00 2001 From: Yong Cong Sin Date: Sat, 25 May 2024 12:40:13 +0800 Subject: [PATCH] debug: remove DEBUG_INFO from EXCEPTION_STACK_TRACE The `DEBUG_INFO` in the `EXCEPTION_STACK_TRACE` is only required by x86. Move that to `X86_EXCEPTION_STACK_TRACE` instead. Signed-off-by: Yong Cong Sin --- arch/x86/core/Kconfig.ia32 | 1 + arch/x86/core/Kconfig.intel64 | 1 + subsys/debug/Kconfig | 1 - tests/arch/common/stack_unwind/prj.conf | 1 - tests/arch/common/stack_unwind/testcase.yaml | 1 + 5 files changed, 3 insertions(+), 2 deletions(-) diff --git a/arch/x86/core/Kconfig.ia32 b/arch/x86/core/Kconfig.ia32 index d789c87eb80..cd2d0d23a92 100644 --- a/arch/x86/core/Kconfig.ia32 +++ b/arch/x86/core/Kconfig.ia32 @@ -167,6 +167,7 @@ config X86_EXCEPTION_STACK_TRACE bool default y depends on EXCEPTION_STACK_TRACE + depends on DEBUG_INFO help Internal config to enable runtime stack traces on fatal exceptions. diff --git a/arch/x86/core/Kconfig.intel64 b/arch/x86/core/Kconfig.intel64 index 2e6e7ebd00a..00c4882a079 100644 --- a/arch/x86/core/Kconfig.intel64 +++ b/arch/x86/core/Kconfig.intel64 @@ -33,6 +33,7 @@ config X86_EXCEPTION_STACK_TRACE bool default y depends on EXCEPTION_STACK_TRACE + depends on DEBUG_INFO depends on NO_OPTIMIZATIONS help Internal config to enable runtime stack traces on fatal exceptions. diff --git a/subsys/debug/Kconfig b/subsys/debug/Kconfig index 40eb73bb370..06dbe50a428 100644 --- a/subsys/debug/Kconfig +++ b/subsys/debug/Kconfig @@ -382,7 +382,6 @@ config SYMTAB config EXCEPTION_STACK_TRACE bool "Attempt to print stack traces upon exceptions" default y - depends on DEBUG_INFO depends on !OMIT_FRAME_POINTER help If the architecture fatal handling code supports it, attempt to diff --git a/tests/arch/common/stack_unwind/prj.conf b/tests/arch/common/stack_unwind/prj.conf index 8ac350b3c97..f22bc03e90b 100644 --- a/tests/arch/common/stack_unwind/prj.conf +++ b/tests/arch/common/stack_unwind/prj.conf @@ -5,4 +5,3 @@ CONFIG_LOG_BUFFER_SIZE=2048 CONFIG_EXCEPTION_STACK_TRACE=y CONFIG_DEBUG=y -CONFIG_DEBUG_INFO=y diff --git a/tests/arch/common/stack_unwind/testcase.yaml b/tests/arch/common/stack_unwind/testcase.yaml index 41c7f95ab8f..ae53406202c 100644 --- a/tests/arch/common/stack_unwind/testcase.yaml +++ b/tests/arch/common/stack_unwind/testcase.yaml @@ -32,6 +32,7 @@ tests: arch_allow: x86 extra_configs: - CONFIG_NO_OPTIMIZATIONS=y + - CONFIG_DEBUG_INFO=y integration_platforms: - qemu_x86 - qemu_x86_64