menu "Kernel hacking" source "lib/Kconfig.debug" config EARLY_PRINTK bool "Early printk" if EMBEDDED default y help Write kernel log output directly into the VGA buffer or to a serial port. This is useful for kernel debugging when your machine crashes very early before the console code is initialized. For normal operation it is not recommended because it looks ugly and doesn't cooperate with klogd/syslogd or the X server. You should normally N here, unless you want to debug such a crash. config KPROBES bool "Kprobes" depends on DEBUG_KERNEL help Kprobes allows you to trap at almost any kernel address and execute a callback function. register_kprobe() establishes a probepoint and specifies the callback. Kprobes is useful for kernel debugging, non-intrusive instrumentation and testing. If in doubt, say "N". config DEBUG_PAGEALLOC bool "Page alloc debugging" depends on DEBUG_KERNEL help Unmap pages from the kernel linear mapping after free_pages(). This results in a large slowdown, but helps to find certain types of memory corruptions. config DEBUG_STACKOVERFLOW bool "Check for stack overflows" depends on DEBUG_KERNEL config DEBUG_STACK_USAGE bool "Stack utilization instrumentation" depends on DEBUG_KERNEL 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. This option will slow down process creation somewhat. config IRQSTACKS bool "Use separate IRQ stacks" help This option subsumes the IRQ stack implementation of the orig. 4KSTACK support. You must use this if you select 4KB stacks! config STACK_SIZE_SHIFT int "Kernel stack size (12 => 4KB, 13 => 8KB, 14 => 16KB)" range 12 14 default 12 if IRQSTACKS default 13 help Select kernel stack size. 4KB stacks are best as they let the system scale further. Use 8KB stacks if you have an experimental kernel where a stack overlow with a 4KB stack might occur. Use 16KB stacks if you want to safely support Windows device drivers using either Linuxant or ndiswrapper. config STACK_WARN int "Print stack trace when stack grows beyond specified bytes" default 4096 if IRQSTACKS default 4096 help The kernel will print a stack trace when the current stack exceeds the specified size. config X86_STACK_CHECK bool "Aggressively check for stack overflows" default n help Say Y here to have the kernel attempt to detect when the per-task kernel stack overflows. Some older versions of gcc don't handle the -p option correctly. Kernprof is affected by the same problem, which is described here: http://oss.sgi.com/projects/kernprof/faq.html#Q9 Basically, if you get oopses in __free_pages_ok during boot when you have this turned on, you need to fix gcc. The Redhat 2.96 version and gcc-3.x seem to work. If not debugging a stack overflow problem, say N config STACK_PANIC int "Panic when stack approaches with specified bytes of the stack limit" depends on X86_STACK_CHECK default 512 if IRQSTACKS default 512 help Panic if the stack grows to within specified byte range. config DEBUG_PAGEALLOC bool "Page alloc debugging" depends on DEBUG_KERNEL help Unmap pages from the kernel linear mapping after free_pages(). This results in a large slowdown, but helps to find certain types of memory corruptions. config X86_FIND_SMP_CONFIG bool depends on X86_LOCAL_APIC || X86_VOYAGER default y config X86_MPPARSE bool depends on X86_LOCAL_APIC && !X86_VISWS default y endmenu