Skip to contentSkip to conversation

prohibit rcutorture from being compiled into the kernel

PATCH In review Paul E. McKenney 2 participants 2 messages May 16, 2007 Library code

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 prohibit rcutorture from being compiled into the kernel

Hello!

There have been a number of instances where people have accidentally compiled rcutorture into the kernel (CONFIG_RCU_TORTURE_TEST=y), which has never been useful, and has often resulted in great frustration. The attached patch prohibits rcutorture from being compiled into the kernel. It may be excluded altogether or compiled as a module. People wishing to have rcutorture hammer their machine immediately upon boot are free to hand-edit lib/Kconfig.debug to remove the "depends on m" line.

Thanks to Randy Dunlap for the trick that makes this work.

---

 Kconfig.debug |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
lib/Kconfig.debug +1 -2
diff -urpNa -X dontdiff linux-2.6.21/lib/Kconfig.debug linux-2.6.21-rcutorturemodonly/lib/Kconfig.debug
@@ -382,14 +382,13 @@ config FORCED_INLINING
 config RCU_TORTURE_TEST
 	tristate "torture tests for RCU"
 	depends on DEBUG_KERNEL
+	depends on m
 	default n
 	help
 	  This option provides a kernel module that runs torture tests
 	  on the RCU infrastructure.  The kernel module may be built
 	  after the fact on the running kernel to be tested, if desired.
 
-	  Say Y here if you want RCU torture tests to start automatically
-	  at boot time (you probably don't).
 	  Say M if you want the RCU torture tests to build as a module.
 	  Say N if you are unsure.
 
Acked-by on v1 1/1
#1 lore raw
Quoted 11 lines · Paul E. McKenney

There have been a number of instances where people have accidentally compiled rcutorture into the kernel (CONFIG_RCU_TORTURE_TEST=y), which has never been useful, and has often resulted in great frustration. The attached patch prohibits rcutorture from being compiled into the kernel. It may be excluded altogether or compiled as a module. People wishing to have rcutorture hammer their machine immediately upon boot are free to hand-edit lib/Kconfig.debug to remove the "depends on m" line.

Thanks to Randy Dunlap for the trick that makes this work.

This seems reasonable to me. I can imagine legitimate reasons to want to have rcutorture running as early as possible, but as you said, anyone wishing to do so can hand-edit lib/Kconfig.debug easily enough.

- Josh Triplett