Skip to contentSkip to conversation

DEBUG_KERNEL menu cleanups

RFC PATCH In review Adrian Bunk 2 participants 3 messages Apr 14, 2006 – Apr 19, 2006 Library code

lore
Share & tools
lore
#0 lore raw

RFC PATCH 1/1 DEBUG_KERNEL menu cleanups

This patch contains the following possible cleanups:
- move DEBUG_FS above the DEBUG_KERNEL options (it did break the menu)
- let the following options depend on DEBUG_KERNEL:
- PRINTK_TIME
- DEBUG_SHIRQ
- RT_MUTEX_TESTER
- UNWIND_INFO
- fix the formatting of the DEBUG_SHIRQ help text

---

 lib/Kconfig.debug |   59 +++++++++++++++++++++++-----------------------
 1 file changed, 30 insertions(+), 29 deletions(-)
lib/Kconfig.debug renamed from lib/Kconfig.debug.old +30 -29
@@ -1,14 +1,4 @@
 
-config PRINTK_TIME
-	bool "Show timing information on printks"
-	help
-	  Selecting this option causes timing information to be
-	  included in printk output.  This allows you to measure
-	  the interval between kernel operations, including bootup
-	  operations.  This is useful for identifying long delays
-	  in kernel startup.
-
-
 config MAGIC_SYSRQ
 	bool "Magic SysRq key"
 	depends on !UML
@@ -23,14 +13,15 @@
 	  keys are documented in <file:Documentation/sysrq.txt>. Don't say Y
 	  unless you really know what this hack does.
 
-config DEBUG_SHIRQ
-       bool "Debug shared IRQ handlers"
-       depends on GENERIC_HARDIRQS
-       help
-         Enable this to generate a spurious interrupt as soon as a shared interrupt
-	 handler is registered, and just before one is deregistered. Drivers ought
-	 to be able to handle interrupts coming in at those points; some don't and
-	 need to be caught.
+config DEBUG_FS
+	bool "Debug Filesystem"
+	depends on SYSFS
+	help
+	  debugfs is a virtual file system that kernel developers use to put
+	  debugging files into.  Enable this option to be able to read and
+	  write to these files.
+
+	  If unsure, say N.
 
 config DEBUG_KERNEL
 	bool "Kernel debugging"
@@ -38,6 +29,25 @@
 	  Say Y here if you are developing drivers or trying to debug and
 	  identify kernel problems.
 
+config PRINTK_TIME
+	bool "Show timing information on printks"
+	depends on DEBUG_KERNEL
+	help
+	  Selecting this option causes timing information to be
+	  included in printk output.  This allows you to measure
+	  the interval between kernel operations, including bootup
+	  operations.  This is useful for identifying long delays
+	  in kernel startup.
+
+config DEBUG_SHIRQ
+       bool "Debug shared IRQ handlers"
+       depends on GENERIC_HARDIRQS && DEBUG_KERNEL
+       help
+         Enable this to generate a spurious interrupt as soon as a shared
+	 interrupt handler is registered, and just before one is deregistered.
+	 Drivers ought to be able to handle interrupts coming in at those
+	 points; some don't and need to be caught.
+
 config LOG_BUF_SHIFT
 	int "Kernel log buffer size (16 => 64KB, 17 => 128KB)" if DEBUG_KERNEL
 	range 12 21
@@ -136,7 +146,7 @@
 
 config RT_MUTEX_TESTER
 	bool "Built-in scriptable tester for rt-mutexes"
-	depends on RT_MUTEXES
+	depends on RT_MUTEXES && DEBUG_KERNEL
 	default n
 	help
 	  This option enables a rt-mutex tester.
@@ -201,16 +211,6 @@
 
 	  If unsure, say N.
 
-config DEBUG_FS
-	bool "Debug Filesystem"
-	depends on SYSFS
-	help
-	  debugfs is a virtual file system that kernel developers use to put
-	  debugging files into.  Enable this option to be able to read and
-	  write to these files.
-
-	  If unsure, say N.
-
 config DEBUG_VM
 	bool "Debug VM"
 	depends on DEBUG_KERNEL
@@ -232,6 +232,7 @@
 
 config UNWIND_INFO
 	bool "Compile the kernel with frame unwind information"
+	depends on DEBUG_KERNEL
 	depends on !IA64
 	depends on !MODULES || !(MIPS || PARISC || PPC || SUPERH || SPARC64 || V850)
 	help
#1 lore raw
Quoted 7 lines · Adrian Bunk

This patch contains the following possible cleanups:
- move DEBUG_FS above the DEBUG_KERNEL options (it did break the menu)
- let the following options depend on DEBUG_KERNEL:
- PRINTK_TIME
- DEBUG_SHIRQ
- RT_MUTEX_TESTER
- UNWIND_INFO

A simpler solution would be to wrap everything inside if DEBUG_KERNEL
...
...
...
endif

Sam

#2 lore raw
Quoted 9 lines · Sam Ravnborg
Quoted 7 lines · Adrian Bunk

This patch contains the following possible cleanups:
- move DEBUG_FS above the DEBUG_KERNEL options (it did break the menu)
- let the following options depend on DEBUG_KERNEL:
- PRINTK_TIME
- DEBUG_SHIRQ
- RT_MUTEX_TESTER
- UNWIND_INFO

Quoted 6 lines

A simpler solution would be to wrap everything inside if DEBUG_KERNEL
...
...
...
endif

It isn't that simple, since this if block would also contain

config LOG_BUF_SHIFT

        int "Kernel log buffer size (16 => 64KB, 17 => 128KB)" if DEBUG_KERNEL
        range 12 21
        ...
Quoted 1 line

Sam

cu
Adrian

Signature · 4 lines
       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed