Commit 3be5cbcd authored by Changbin Du's avatar Changbin Du Committed by Linus Torvalds

kernel-hacking: group kernel data structures debugging together

Group these similar runtime data structures verification options
together.

Link: http://lkml.kernel.org/r/20190909144453.3520-4-changbin.du@gmail.comSigned-off-by: default avatarChangbin Du <changbin.du@gmail.com>
Acked-by: default avatarRandy Dunlap <rdunlap@infradead.org>
Tested-by: default avatarRandy Dunlap <rdunlap@infradead.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent ff600a9a
...@@ -1355,6 +1355,8 @@ config DEBUG_BUGVERBOSE ...@@ -1355,6 +1355,8 @@ config DEBUG_BUGVERBOSE
of the BUG call as well as the EIP and oops trace. This aids of the BUG call as well as the EIP and oops trace. This aids
debugging but costs about 70-100K of memory. debugging but costs about 70-100K of memory.
menu "Debug kernel data structures"
config DEBUG_LIST config DEBUG_LIST
bool "Debug linked list manipulation" bool "Debug linked list manipulation"
depends on DEBUG_KERNEL || BUG_ON_DATA_CORRUPTION depends on DEBUG_KERNEL || BUG_ON_DATA_CORRUPTION
...@@ -1394,6 +1396,18 @@ config DEBUG_NOTIFIERS ...@@ -1394,6 +1396,18 @@ config DEBUG_NOTIFIERS
This is a relatively cheap check but if you care about maximum This is a relatively cheap check but if you care about maximum
performance, say N. performance, say N.
config BUG_ON_DATA_CORRUPTION
bool "Trigger a BUG when data corruption is detected"
select DEBUG_LIST
help
Select this option if the kernel should BUG when it encounters
data corruption in kernel memory structures when they get checked
for validity.
If unsure, say N.
endmenu
config DEBUG_CREDENTIALS config DEBUG_CREDENTIALS
bool "Debug credential management" bool "Debug credential management"
depends on DEBUG_KERNEL depends on DEBUG_KERNEL
...@@ -2107,16 +2121,6 @@ config MEMTEST ...@@ -2107,16 +2121,6 @@ config MEMTEST
memtest=17, mean do 17 test patterns. memtest=17, mean do 17 test patterns.
If you are unsure how to answer this question, answer N. If you are unsure how to answer this question, answer N.
config BUG_ON_DATA_CORRUPTION
bool "Trigger a BUG when data corruption is detected"
select DEBUG_LIST
help
Select this option if the kernel should BUG when it encounters
data corruption in kernel memory structures when they get checked
for validity.
If unsure, say N.
source "samples/Kconfig" source "samples/Kconfig"
config ARCH_HAS_DEVMEM_IS_ALLOWED config ARCH_HAS_DEVMEM_IS_ALLOWED
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment