kconfig: Move debugging-related options from misc/ to subsys/debug/
This should fix the grouping for debugging options appearing in the main "menuconfig" menu. Change-Id: I7ddf3a6f3d025bf82ba63099b30e47a40d7c3187 Signed-off-by: Leandro Pereira <leandro.pereira@intel.com>
This commit is contained in:
parent
c40239dcfa
commit
86b0260e97
2 changed files with 121 additions and 122 deletions
122
misc/Kconfig
122
misc/Kconfig
|
@ -150,128 +150,6 @@ config KERNEL_BIN_NAME
|
|||
|
||||
endmenu
|
||||
|
||||
menu "Debugging Options"
|
||||
|
||||
config DEBUG
|
||||
bool "Build kernel with debugging enabled"
|
||||
default n
|
||||
help
|
||||
Build a kernel suitable for debugging. Right now, this option
|
||||
only disables optimization, more debugging variants can be selected
|
||||
from here to allow more debugging.
|
||||
|
||||
config STACK_USAGE
|
||||
bool "Generate stack usage information"
|
||||
default n
|
||||
help
|
||||
Generate an extra file that specifies the maximum amount of stack used,
|
||||
on a per-function basis.
|
||||
|
||||
config PRINTK
|
||||
bool
|
||||
prompt "Send printk() to console"
|
||||
depends on CONSOLE_HAS_DRIVER
|
||||
default y
|
||||
help
|
||||
This option directs printk() debugging output to the supported
|
||||
console device, rather than suppressing the generation
|
||||
of printk() output entirely. Output is sent immediately, without
|
||||
any mutual exclusion or buffering.
|
||||
|
||||
config STDOUT_CONSOLE
|
||||
bool
|
||||
prompt "Send stdout to console"
|
||||
depends on CONSOLE_HAS_DRIVER
|
||||
default n
|
||||
help
|
||||
This option directs standard output (e.g. printf) to the console
|
||||
device, rather than suppressing it entirely.
|
||||
|
||||
config EARLY_CONSOLE
|
||||
bool
|
||||
prompt "Send stdout at the earliest stage possible"
|
||||
default n
|
||||
help
|
||||
This option will enable stdout as early as possible, for debugging
|
||||
purpose. For instance, in case of STDOUT_CONSOLE being set it will
|
||||
initialize its driver earlier than normal, in order to get the stdout
|
||||
sent through the console at the earliest stage possible.
|
||||
|
||||
config ASSERT
|
||||
bool
|
||||
prompt "Enable __ASSERT() macro"
|
||||
default n
|
||||
help
|
||||
This enables the __ASSERT() macro in the kernel code. If an assertion
|
||||
fails, the calling thread is put on an infinite tight loop. Since
|
||||
enabling this adds a significant footprint, it should only be enabled
|
||||
in a non-production system.
|
||||
|
||||
config ASSERT_LEVEL
|
||||
int
|
||||
prompt "__ASSERT() level"
|
||||
default 2
|
||||
range 0 2
|
||||
depends on ASSERT
|
||||
help
|
||||
This option specifies the assertion level used by the __ASSERT()
|
||||
macro. It can be set to one of three possible values:
|
||||
|
||||
Level 0: off
|
||||
Level 1: on + warning in every file that includes __assert.h
|
||||
Level 2: on + no warning
|
||||
|
||||
config DEBUG_TRACING_KERNEL_OBJECTS
|
||||
bool "Kernel object tracing (deprecated)"
|
||||
select OBJECT_TRACING
|
||||
default n
|
||||
help
|
||||
For backward compatibility only
|
||||
|
||||
config OBJECT_TRACING
|
||||
bool
|
||||
prompt "Kernel object tracing"
|
||||
default n
|
||||
help
|
||||
This option enable the feature for tracing kernel objects. This option
|
||||
is for debug purposes and increases the memory footprint of the kernel.
|
||||
|
||||
config OVERRIDE_FRAME_POINTER_DEFAULT
|
||||
bool
|
||||
prompt "Override compiler defaults for -fomit-frame-pointer"
|
||||
default n
|
||||
help
|
||||
Omitting the frame pointer prevents the compiler from putting the stack
|
||||
frame pointer into a register. Saves a few instructions in function
|
||||
prologues/epilogues and frees up a register for general-purpose use,
|
||||
which can provide good performance improvements on register-constrained
|
||||
architectures like x86. On some architectures (including x86) omitting
|
||||
frame pointers impedes debugging as local variables are harder to
|
||||
locate. At -O1 and above gcc will enable -fomit-frame-pointer
|
||||
automatically but only if the architecture does not require if for
|
||||
effective debugging.
|
||||
|
||||
Choose Y if you want to override the default frame pointer behavior
|
||||
of your compiler, otherwise choose N.
|
||||
|
||||
config OMIT_FRAME_POINTER
|
||||
bool
|
||||
prompt "Omit frame pointer"
|
||||
default n
|
||||
depends on OVERRIDE_FRAME_POINTER_DEFAULT
|
||||
help
|
||||
Choose Y for best performance. On some architectures (including x86)
|
||||
this will favor code size and performance over debugability.
|
||||
|
||||
Choose N in you wish to retain the frame pointer. This option may
|
||||
be useful if your application uses runtime backtracing and does not
|
||||
support parsing unwind tables.
|
||||
|
||||
If unsure, disable OVERRIDE_FRAME_POINTER_DEFAULT to allow the compiler
|
||||
to adopt sensible defaults for your architecture.
|
||||
|
||||
endmenu
|
||||
|
||||
menu "System Monitoring Options"
|
||||
|
||||
config PERFORMANCE_METRICS
|
||||
|
|
|
@ -6,6 +6,125 @@
|
|||
# SPDX-License-Identifier: Apache-2.0
|
||||
#
|
||||
|
||||
menu "Debugging Options"
|
||||
|
||||
config DEBUG
|
||||
bool "Build kernel with debugging enabled"
|
||||
default n
|
||||
help
|
||||
Build a kernel suitable for debugging. Right now, this option
|
||||
only disables optimization, more debugging variants can be selected
|
||||
from here to allow more debugging.
|
||||
|
||||
config STACK_USAGE
|
||||
bool "Generate stack usage information"
|
||||
default n
|
||||
help
|
||||
Generate an extra file that specifies the maximum amount of stack used,
|
||||
on a per-function basis.
|
||||
|
||||
config PRINTK
|
||||
bool
|
||||
prompt "Send printk() to console"
|
||||
depends on CONSOLE_HAS_DRIVER
|
||||
default y
|
||||
help
|
||||
This option directs printk() debugging output to the supported
|
||||
console device, rather than suppressing the generation
|
||||
of printk() output entirely. Output is sent immediately, without
|
||||
any mutual exclusion or buffering.
|
||||
|
||||
config STDOUT_CONSOLE
|
||||
bool
|
||||
prompt "Send stdout to console"
|
||||
depends on CONSOLE_HAS_DRIVER
|
||||
default n
|
||||
help
|
||||
This option directs standard output (e.g. printf) to the console
|
||||
device, rather than suppressing it entirely.
|
||||
|
||||
config EARLY_CONSOLE
|
||||
bool
|
||||
prompt "Send stdout at the earliest stage possible"
|
||||
default n
|
||||
help
|
||||
This option will enable stdout as early as possible, for debugging
|
||||
purpose. For instance, in case of STDOUT_CONSOLE being set it will
|
||||
initialize its driver earlier than normal, in order to get the stdout
|
||||
sent through the console at the earliest stage possible.
|
||||
|
||||
config ASSERT
|
||||
bool
|
||||
prompt "Enable __ASSERT() macro"
|
||||
default n
|
||||
help
|
||||
This enables the __ASSERT() macro in the kernel code. If an assertion
|
||||
fails, the calling thread is put on an infinite tight loop. Since
|
||||
enabling this adds a significant footprint, it should only be enabled
|
||||
in a non-production system.
|
||||
|
||||
config ASSERT_LEVEL
|
||||
int
|
||||
prompt "__ASSERT() level"
|
||||
default 2
|
||||
range 0 2
|
||||
depends on ASSERT
|
||||
help
|
||||
This option specifies the assertion level used by the __ASSERT()
|
||||
macro. It can be set to one of three possible values:
|
||||
|
||||
Level 0: off
|
||||
Level 1: on + warning in every file that includes __assert.h
|
||||
Level 2: on + no warning
|
||||
|
||||
config DEBUG_TRACING_KERNEL_OBJECTS
|
||||
bool "Kernel object tracing (deprecated)"
|
||||
select OBJECT_TRACING
|
||||
default n
|
||||
help
|
||||
For backward compatibility only
|
||||
|
||||
config OBJECT_TRACING
|
||||
bool
|
||||
prompt "Kernel object tracing"
|
||||
default n
|
||||
help
|
||||
This option enable the feature for tracing kernel objects. This option
|
||||
is for debug purposes and increases the memory footprint of the kernel.
|
||||
|
||||
config OVERRIDE_FRAME_POINTER_DEFAULT
|
||||
bool
|
||||
prompt "Override compiler defaults for -fomit-frame-pointer"
|
||||
default n
|
||||
help
|
||||
Omitting the frame pointer prevents the compiler from putting the stack
|
||||
frame pointer into a register. Saves a few instructions in function
|
||||
prologues/epilogues and frees up a register for general-purpose use,
|
||||
which can provide good performance improvements on register-constrained
|
||||
architectures like x86. On some architectures (including x86) omitting
|
||||
frame pointers impedes debugging as local variables are harder to
|
||||
locate. At -O1 and above gcc will enable -fomit-frame-pointer
|
||||
automatically but only if the architecture does not require if for
|
||||
effective debugging.
|
||||
|
||||
Choose Y if you want to override the default frame pointer behavior
|
||||
of your compiler, otherwise choose N.
|
||||
|
||||
config OMIT_FRAME_POINTER
|
||||
bool
|
||||
prompt "Omit frame pointer"
|
||||
default n
|
||||
depends on OVERRIDE_FRAME_POINTER_DEFAULT
|
||||
help
|
||||
Choose Y for best performance. On some architectures (including x86)
|
||||
this will favor code size and performance over debugability.
|
||||
|
||||
Choose N in you wish to retain the frame pointer. This option may
|
||||
be useful if your application uses runtime backtracing and does not
|
||||
support parsing unwind tables.
|
||||
|
||||
If unsure, disable OVERRIDE_FRAME_POINTER_DEFAULT to allow the compiler
|
||||
to adopt sensible defaults for your architecture.
|
||||
|
||||
menu "Safe memory access"
|
||||
|
||||
|
@ -129,3 +248,5 @@ config OPENOCD_SUPPORT
|
|||
This option exports an array of offsets to kernel structs, used by
|
||||
OpenOCD to determine the state of running threads. (This option
|
||||
selects CONFIG_THREAD_MONITOR, so all of its caveats are implied.)
|
||||
|
||||
endmenu
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue