Skip to contentSkip to conversation

Create and populate toplevel tests/ for kernel tests

PATCH In review Ananth N Mavinakayanahalli 8 participants 26 messages Feb 11, 2008 – Feb 22, 2008

Subsystems (5)
lore
Share & tools
lore
#0 lore raw

cover Create and populate toplevel tests/ for kernel tests

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

Ananth

#1 lore raw

PATCH 1/8 Create tests/ directory

From: Ananth N Mavinakayanahalli <[email protected]>

Create a toplevel tests/ directory to house in-kernel subsystem specific tests.

Thanks to Sam Ravnborg for the Makefile corrections.

---
 Makefile          |    1 +
 lib/Kconfig.debug |    2 ++
 tests/Kconfig     |   10 ++++++++++
 tests/Makefile    |    3 +++
 4 files changed, 16 insertions(+)
Makefile +1 -0
Index: linux-2.6.25-rc1/Makefile
===================================================================
@@ -603,6 +603,7 @@ export mod_strip_cmd
 
 ifeq ($(KBUILD_EXTMOD),)
 core-y		+= kernel/ mm/ fs/ ipc/ security/ crypto/ block/
+core-$(CONFIG_KERNEL_TESTS) += tests/
 
 vmlinux-dirs	:= $(patsubst %/,%,$(filter %/, $(init-y) $(init-m) \
 		     $(core-y) $(core-m) $(drivers-y) $(drivers-m) \
lib/Kconfig.debug +2 -0
Index: linux-2.6.25-rc1/lib/Kconfig.debug
===================================================================
@@ -618,3 +618,5 @@ config PROVIDE_OHCI1394_DMA_INIT
 	  See Documentation/debugging-via-ohci1394.txt for more information.
 
 source "samples/Kconfig"
+
+source "tests/Kconfig"
tests/Kconfig new file +10 -0
Index: linux-2.6.25-rc1/tests/Kconfig
===================================================================
@@ -0,0 +1,10 @@
+# tests/Kconfig
+
+menuconfig KERNEL_TESTS
+	bool "Kernel subsystem tests"
+	help
+	  You can build kernel subsystem specific tests.
+
+if KERNEL_TESTS
+
+endif # KERNEL_TESTS
tests/Makefile new file +3 -0
Index: linux-2.6.25-rc1/tests/Makefile
===================================================================
@@ -0,0 +1,3 @@
+#
+# Makefile for kernel subsystem specific tests
+#
#2 lore raw

PATCH 2/8 Move locking selftests to tests/

In reply to Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move the locking-selftest infrastructure to tests/

---
 lib/locking-selftest-hardirq.h         |    9 
 lib/locking-selftest-mutex.h           |   11 
 lib/locking-selftest-rlock-hardirq.h   |    2 
 lib/locking-selftest-rlock-softirq.h   |    2 
 lib/locking-selftest-rlock.h           |   14 
 lib/locking-selftest-rsem.h            |   14 
 lib/locking-selftest-softirq.h         |    9 
 lib/locking-selftest-spin-hardirq.h    |    2 
 lib/locking-selftest-spin-softirq.h    |    2 
 lib/locking-selftest-spin.h            |   11 
 lib/locking-selftest-wlock-hardirq.h   |    2 
 lib/locking-selftest-wlock-softirq.h   |    2 
 lib/locking-selftest-wlock.h           |   14 
 lib/locking-selftest-wsem.h            |   14 
 lib/locking-selftest.c                 | 1218 ---------------------------------
 lib/Kconfig.debug                      |   11 
 lib/Makefile                           |    1 
 tests/Kconfig                          |   11 
 tests/Makefile                         |    2 
 tests/locking-selftest-hardirq.h       |    9 
 tests/locking-selftest-mutex.h         |   11 
 tests/locking-selftest-rlock-hardirq.h |    2 
 tests/locking-selftest-rlock-softirq.h |    2 
 tests/locking-selftest-rlock.h         |   14 
 tests/locking-selftest-rsem.h          |   14 
 tests/locking-selftest-softirq.h       |    9 
 tests/locking-selftest-spin-hardirq.h  |    2 
 tests/locking-selftest-spin-softirq.h  |    2 
 tests/locking-selftest-spin.h          |   11 
 tests/locking-selftest-wlock-hardirq.h |    2 
 tests/locking-selftest-wlock-softirq.h |    2 
 tests/locking-selftest-wlock.h         |   14 
 tests/locking-selftest-wsem.h          |   14 
 tests/locking-selftest.c               | 1218 +++++++++++++++++++++++++++++++++
 34 files changed, 1339 insertions(+), 1338 deletions(-)
lib/Kconfig.debug +0 -11
Index: linux-2.6.25-rc1/lib/Kconfig.debug
===================================================================
@@ -371,17 +371,6 @@ config DEBUG_SPINLOCK_SLEEP
 	  If you say Y here, various routines which may sleep will become very
 	  noisy if they are called with a spinlock held.
 
-config DEBUG_LOCKING_API_SELFTESTS
-	bool "Locking API boot-time self-tests"
-	depends on DEBUG_KERNEL
-	help
-	  Say Y here if you want the kernel to run a short self-test during
-	  bootup. The self-test checks whether common types of locking bugs
-	  are detected by debugging mechanisms or not. (if you disable
-	  lock debugging then those bugs wont be detected of course.)
-	  The following locking APIs are covered: spinlocks, rwlocks,
-	  mutexes and rwsems.
-
 config STACKTRACE
 	bool
 	depends on DEBUG_KERNEL
lib/Makefile +0 -1
Index: linux-2.6.25-rc1/lib/Makefile
===================================================================
@@ -25,7 +25,6 @@ lib-$(CONFIG_HOTPLUG) += kobject_uevent.
 obj-$(CONFIG_GENERIC_IOMAP) += iomap.o
 obj-$(CONFIG_HAS_IOMEM) += iomap_copy.o devres.o
 obj-$(CONFIG_CHECK_SIGNATURE) += check_signature.o
-obj-$(CONFIG_DEBUG_LOCKING_API_SELFTESTS) += locking-selftest.o
 obj-$(CONFIG_DEBUG_SPINLOCK) += spinlock_debug.o
 lib-$(CONFIG_RWSEM_GENERIC_SPINLOCK) += rwsem-spinlock.o
 lib-$(CONFIG_RWSEM_XCHGADD_ALGORITHM) += rwsem.o
lib/locking-selftest-hardirq.h deleted +0 -9
Index: linux-2.6.25-rc1/lib/locking-selftest-hardirq.h
===================================================================
@@ -1,9 +0,0 @@
-#undef IRQ_DISABLE
-#undef IRQ_ENABLE
-#undef IRQ_ENTER
-#undef IRQ_EXIT
-
-#define IRQ_ENABLE		HARDIRQ_ENABLE
-#define IRQ_DISABLE		HARDIRQ_DISABLE
-#define IRQ_ENTER		HARDIRQ_ENTER
-#define IRQ_EXIT		HARDIRQ_EXIT
lib/locking-selftest-mutex.h deleted +0 -11
Index: linux-2.6.25-rc1/lib/locking-selftest-mutex.h
===================================================================
@@ -1,11 +0,0 @@
-#undef LOCK
-#define LOCK		ML
-
-#undef UNLOCK
-#define UNLOCK		MU
-
-#undef RLOCK
-#undef WLOCK
-
-#undef INIT
-#define INIT		MI
lib/locking-selftest-rlock-hardirq.h deleted +0 -2
Index: linux-2.6.25-rc1/lib/locking-selftest-rlock-hardirq.h
===================================================================
@@ -1,2 +0,0 @@
-#include "locking-selftest-rlock.h"
-#include "locking-selftest-hardirq.h"
lib/locking-selftest-rlock-softirq.h deleted +0 -2
Index: linux-2.6.25-rc1/lib/locking-selftest-rlock-softirq.h
===================================================================
@@ -1,2 +0,0 @@
-#include "locking-selftest-rlock.h"
-#include "locking-selftest-softirq.h"
lib/locking-selftest-rlock.h deleted +0 -14
Index: linux-2.6.25-rc1/lib/locking-selftest-rlock.h
===================================================================
@@ -1,14 +0,0 @@
-#undef LOCK
-#define LOCK		RL
-
-#undef UNLOCK
-#define UNLOCK		RU
-
-#undef RLOCK
-#define RLOCK		RL
-
-#undef WLOCK
-#define WLOCK		WL
-
-#undef INIT
-#define INIT		RWI
lib/locking-selftest-rsem.h deleted +0 -14
Index: linux-2.6.25-rc1/lib/locking-selftest-rsem.h
===================================================================
@@ -1,14 +0,0 @@
-#undef LOCK
-#define LOCK		RSL
-
-#undef UNLOCK
-#define UNLOCK		RSU
-
-#undef RLOCK
-#define RLOCK		RSL
-
-#undef WLOCK
-#define WLOCK		WSL
-
-#undef INIT
-#define INIT		RWSI
lib/locking-selftest-softirq.h deleted +0 -9
Index: linux-2.6.25-rc1/lib/locking-selftest-softirq.h
===================================================================
@@ -1,9 +0,0 @@
-#undef IRQ_DISABLE
-#undef IRQ_ENABLE
-#undef IRQ_ENTER
-#undef IRQ_EXIT
-
-#define IRQ_DISABLE		SOFTIRQ_DISABLE
-#define IRQ_ENABLE		SOFTIRQ_ENABLE
-#define IRQ_ENTER		SOFTIRQ_ENTER
-#define IRQ_EXIT		SOFTIRQ_EXIT
lib/locking-selftest-spin-hardirq.h deleted +0 -2
Index: linux-2.6.25-rc1/lib/locking-selftest-spin-hardirq.h
===================================================================
@@ -1,2 +0,0 @@
-#include "locking-selftest-spin.h"
-#include "locking-selftest-hardirq.h"
lib/locking-selftest-spin-softirq.h deleted +0 -2
Index: linux-2.6.25-rc1/lib/locking-selftest-spin-softirq.h
===================================================================
@@ -1,2 +0,0 @@
-#include "locking-selftest-spin.h"
-#include "locking-selftest-softirq.h"
lib/locking-selftest-spin.h deleted +0 -11
Index: linux-2.6.25-rc1/lib/locking-selftest-spin.h
===================================================================
@@ -1,11 +0,0 @@
-#undef LOCK
-#define LOCK		L
-
-#undef UNLOCK
-#define UNLOCK		U
-
-#undef RLOCK
-#undef WLOCK
-
-#undef INIT
-#define INIT		SI
lib/locking-selftest-wlock-hardirq.h deleted +0 -2
Index: linux-2.6.25-rc1/lib/locking-selftest-wlock-hardirq.h
===================================================================
@@ -1,2 +0,0 @@
-#include "locking-selftest-wlock.h"
-#include "locking-selftest-hardirq.h"
lib/locking-selftest-wlock.h deleted +0 -14
Index: linux-2.6.25-rc1/lib/locking-selftest-wlock.h
===================================================================
@@ -1,14 +0,0 @@
-#undef LOCK
-#define LOCK		WL
-
-#undef UNLOCK
-#define UNLOCK		WU
-
-#undef RLOCK
-#define RLOCK		RL
-
-#undef WLOCK
-#define WLOCK		WL
-
-#undef INIT
-#define INIT		RWI
lib/locking-selftest-wsem.h deleted +0 -14
Index: linux-2.6.25-rc1/lib/locking-selftest-wsem.h
===================================================================
@@ -1,14 +0,0 @@
-#undef LOCK
-#define LOCK		WSL
-
-#undef UNLOCK
-#define UNLOCK		WSU
-
-#undef RLOCK
-#define RLOCK		RSL
-
-#undef WLOCK
-#define WLOCK		WSL
-
-#undef INIT
-#define INIT		RWSI
lib/locking-selftest.c deleted +0 -1218

1,218 lines not on this page · raw message

tests/Kconfig +11 -0
Index: linux-2.6.25-rc1/tests/Kconfig
===================================================================
@@ -7,4 +7,15 @@ menuconfig KERNEL_TESTS
 
 if KERNEL_TESTS
 
+config DEBUG_LOCKING_API_SELFTESTS
+	bool "Locking API boot-time self-tests"
+	depends on DEBUG_KERNEL
+	help
+	  Say Y here if you want the kernel to run a short self-test during
+	  bootup. The self-test checks whether common types of locking bugs
+	  are detected by debugging mechanisms or not. (if you disable
+	  lock debugging then those bugs wont be detected of course.)
+	  The following locking APIs are covered: spinlocks, rwlocks,
+	  mutexes and rwsems.
+
 endif # KERNEL_TESTS
tests/Makefile +2 -0
Index: linux-2.6.25-rc1/tests/Makefile
===================================================================
@@ -1,3 +1,5 @@
 #
 # Makefile for kernel subsystem specific tests
 #
+
+obj-$(CONFIG_DEBUG_LOCKING_API_SELFTESTS) += locking-selftest.o
tests/locking-selftest-hardirq.h new file +9 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-hardirq.h
===================================================================
@@ -0,0 +1,9 @@
+#undef IRQ_DISABLE
+#undef IRQ_ENABLE
+#undef IRQ_ENTER
+#undef IRQ_EXIT
+
+#define IRQ_ENABLE		HARDIRQ_ENABLE
+#define IRQ_DISABLE		HARDIRQ_DISABLE
+#define IRQ_ENTER		HARDIRQ_ENTER
+#define IRQ_EXIT		HARDIRQ_EXIT
tests/locking-selftest-mutex.h new file +11 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-mutex.h
===================================================================
@@ -0,0 +1,11 @@
+#undef LOCK
+#define LOCK		ML
+
+#undef UNLOCK
+#define UNLOCK		MU
+
+#undef RLOCK
+#undef WLOCK
+
+#undef INIT
+#define INIT		MI
tests/locking-selftest-rlock-hardirq.h new file +2 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-rlock-hardirq.h
===================================================================
@@ -0,0 +1,2 @@
+#include "locking-selftest-rlock.h"
+#include "locking-selftest-hardirq.h"
tests/locking-selftest-rlock-softirq.h new file +2 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-rlock-softirq.h
===================================================================
@@ -0,0 +1,2 @@
+#include "locking-selftest-rlock.h"
+#include "locking-selftest-softirq.h"
tests/locking-selftest-rlock.h new file +14 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-rlock.h
===================================================================
@@ -0,0 +1,14 @@
+#undef LOCK
+#define LOCK		RL
+
+#undef UNLOCK
+#define UNLOCK		RU
+
+#undef RLOCK
+#define RLOCK		RL
+
+#undef WLOCK
+#define WLOCK		WL
+
+#undef INIT
+#define INIT		RWI
tests/locking-selftest-rsem.h new file +14 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-rsem.h
===================================================================
@@ -0,0 +1,14 @@
+#undef LOCK
+#define LOCK		RSL
+
+#undef UNLOCK
+#define UNLOCK		RSU
+
+#undef RLOCK
+#define RLOCK		RSL
+
+#undef WLOCK
+#define WLOCK		WSL
+
+#undef INIT
+#define INIT		RWSI
tests/locking-selftest-softirq.h new file +9 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-softirq.h
===================================================================
@@ -0,0 +1,9 @@
+#undef IRQ_DISABLE
+#undef IRQ_ENABLE
+#undef IRQ_ENTER
+#undef IRQ_EXIT
+
+#define IRQ_DISABLE		SOFTIRQ_DISABLE
+#define IRQ_ENABLE		SOFTIRQ_ENABLE
+#define IRQ_ENTER		SOFTIRQ_ENTER
+#define IRQ_EXIT		SOFTIRQ_EXIT
tests/locking-selftest-spin-hardirq.h new file +2 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-spin-hardirq.h
===================================================================
@@ -0,0 +1,2 @@
+#include "locking-selftest-spin.h"
+#include "locking-selftest-hardirq.h"
tests/locking-selftest-spin-softirq.h new file +2 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-spin-softirq.h
===================================================================
@@ -0,0 +1,2 @@
+#include "locking-selftest-spin.h"
+#include "locking-selftest-softirq.h"
tests/locking-selftest-spin.h new file +11 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-spin.h
===================================================================
@@ -0,0 +1,11 @@
+#undef LOCK
+#define LOCK		L
+
+#undef UNLOCK
+#define UNLOCK		U
+
+#undef RLOCK
+#undef WLOCK
+
+#undef INIT
+#define INIT		SI
tests/locking-selftest-wlock-hardirq.h new file +2 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-wlock-hardirq.h
===================================================================
@@ -0,0 +1,2 @@
+#include "locking-selftest-wlock.h"
+#include "locking-selftest-hardirq.h"
tests/locking-selftest-wlock.h new file +14 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-wlock.h
===================================================================
@@ -0,0 +1,14 @@
+#undef LOCK
+#define LOCK		WL
+
+#undef UNLOCK
+#define UNLOCK		WU
+
+#undef RLOCK
+#define RLOCK		RL
+
+#undef WLOCK
+#define WLOCK		WL
+
+#undef INIT
+#define INIT		RWI
tests/locking-selftest-wsem.h new file +14 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-wsem.h
===================================================================
@@ -0,0 +1,14 @@
+#undef LOCK
+#define LOCK		WSL
+
+#undef UNLOCK
+#define UNLOCK		WSU
+
+#undef RLOCK
+#define RLOCK		RSL
+
+#undef WLOCK
+#define WLOCK		WSL
+
+#undef INIT
+#define INIT		RWSI
tests/locking-selftest.c new file +1218 -0

1,218 lines not on this page · raw message

lib/locking-selftest-wlock-softirq.h deleted +0 -2
Index: linux-2.6.25-rc1/lib/locking-selftest-wlock-softirq.h
===================================================================
@@ -1,2 +0,0 @@
-#include "locking-selftest-wlock.h"
-#include "locking-selftest-softirq.h"
tests/locking-selftest-wlock-softirq.h new file +2 -0
Index: linux-2.6.25-rc1/tests/locking-selftest-wlock-softirq.h
===================================================================
@@ -0,0 +1,2 @@
+#include "locking-selftest-wlock.h"
+#include "locking-selftest-softirq.h"
#3 lore raw

PATCH 3/8 Move rcutorture to tests/

In reply to Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move the rcutorture infrastructure to tests/

---
 kernel/rcutorture.c |  995 ----------------------------------------------------
 kernel/Makefile     |    1 
 lib/Kconfig.debug   |   13 
 tests/Kconfig       |   13 
 tests/Makefile      |    1 
 tests/rcutorture.c  |  995 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 6 files changed, 1009 insertions(+), 1009 deletions(-)
kernel/Makefile +0 -1
Index: linux-2.6.25-rc1/kernel/Makefile
===================================================================
@@ -56,7 +56,6 @@ obj-$(CONFIG_KPROBES) += kprobes.o
 obj-$(CONFIG_DETECT_SOFTLOCKUP) += softlockup.o
 obj-$(CONFIG_GENERIC_HARDIRQS) += irq/
 obj-$(CONFIG_SECCOMP) += seccomp.o
-obj-$(CONFIG_RCU_TORTURE_TEST) += rcutorture.o
 obj-$(CONFIG_CLASSIC_RCU) += rcuclassic.o
 obj-$(CONFIG_PREEMPT_RCU) += rcupreempt.o
 ifeq ($(CONFIG_PREEMPT_RCU),y)
kernel/rcutorture.c deleted +0 -995

995 lines not on this page · raw message

lib/Kconfig.debug +0 -13
Index: linux-2.6.25-rc1/lib/Kconfig.debug
===================================================================
@@ -472,19 +472,6 @@ config BOOT_PRINTK_DELAY
 	  BOOT_PRINTK_DELAY also may cause DETECT_SOFTLOCKUP to detect
 	  what it believes to be lockup conditions.
 
-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 M if you want the RCU torture tests to build as a module.
-	  Say N if you are unsure.
-
 config KPROBES_SANITY_TEST
 	bool "Kprobes sanity tests"
 	depends on DEBUG_KERNEL
tests/Kconfig +13 -0
Index: linux-2.6.25-rc1/tests/Kconfig
===================================================================
@@ -18,4 +18,17 @@ config DEBUG_LOCKING_API_SELFTESTS
 	  The following locking APIs are covered: spinlocks, rwlocks,
 	  mutexes and rwsems.
 
+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 M if you want the RCU torture tests to build as a module.
+	  Say N if you are unsure.
+
 endif # KERNEL_TESTS
tests/Makefile +1 -0
Index: linux-2.6.25-rc1/tests/Makefile
===================================================================
@@ -3,3 +3,4 @@
 #
 
 obj-$(CONFIG_DEBUG_LOCKING_API_SELFTESTS) += locking-selftest.o
+obj-$(CONFIG_RCU_TORTURE_TEST) += rcutorture.o
tests/rcutorture.c new file +995 -0

995 lines not on this page · raw message

#4 lore raw

PATCH 4/8 Move rtmutex-tests to tests/

In reply to Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move the rtmutex-tester infrastructure to tests/

---
 kernel/rtmutex-tester.c |  442 ------------------------------------------------
 kernel/Makefile         |    1 
 lib/Kconfig.debug       |    6 
 tests/Kconfig           |    6 
 tests/Makefile          |    1 
 tests/rtmutex-tester.c  |  442 ++++++++++++++++++++++++++++++++++++++++++++++++
 6 files changed, 449 insertions(+), 449 deletions(-)
kernel/Makefile +0 -1
Index: linux-2.6.25-rc1/kernel/Makefile
===================================================================
@@ -25,7 +25,6 @@ obj-$(CONFIG_FUTEX) += futex_compat.o
 endif
 obj-$(CONFIG_RT_MUTEXES) += rtmutex.o
 obj-$(CONFIG_DEBUG_RT_MUTEXES) += rtmutex-debug.o
-obj-$(CONFIG_RT_MUTEX_TESTER) += rtmutex-tester.o
 obj-$(CONFIG_GENERIC_ISA_DMA) += dma.o
 obj-$(CONFIG_SMP) += cpu.o spinlock.o
 obj-$(CONFIG_DEBUG_SPINLOCK) += spinlock.o
kernel/rtmutex-tester.c deleted +0 -442

442 lines not on this page · raw message

lib/Kconfig.debug +0 -6
Index: linux-2.6.25-rc1/lib/Kconfig.debug
===================================================================
@@ -240,12 +240,6 @@ config DEBUG_PI_LIST
 	default y
 	depends on DEBUG_RT_MUTEXES
 
-config RT_MUTEX_TESTER
-	bool "Built-in scriptable tester for rt-mutexes"
-	depends on DEBUG_KERNEL && RT_MUTEXES
-	help
-	  This option enables a rt-mutex tester.
-
 config DEBUG_SPINLOCK
 	bool "Spinlock and rw-lock debugging: basic checks"
 	depends on DEBUG_KERNEL
tests/Kconfig +6 -0
Index: linux-2.6.25-rc1/tests/Kconfig
===================================================================
@@ -31,4 +31,10 @@ config RCU_TORTURE_TEST
 	  Say M if you want the RCU torture tests to build as a module.
 	  Say N if you are unsure.
 
+config RT_MUTEX_TESTER
+	bool "Built-in scriptable tester for rt-mutexes"
+	depends on DEBUG_KERNEL && RT_MUTEXES
+	help
+	  This option enables a rt-mutex tester.
+
 endif # KERNEL_TESTS
tests/Makefile +1 -0
Index: linux-2.6.25-rc1/tests/Makefile
===================================================================
@@ -4,3 +4,4 @@
 
 obj-$(CONFIG_DEBUG_LOCKING_API_SELFTESTS) += locking-selftest.o
 obj-$(CONFIG_RCU_TORTURE_TEST) += rcutorture.o
+obj-$(CONFIG_RT_MUTEX_TESTER) += rtmutex-tester.o
tests/rtmutex-tester.c new file +442 -0

442 lines not on this page · raw message

#5 lore raw

PATCH 5/8 Move lkdtm to tests/

In reply to Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move the lkdtm infrastructure to tests/

---
 drivers/misc/lkdtm.c  |  345 --------------------------------------------------
 drivers/misc/Makefile |    1 
 lib/Kconfig.debug     |   15 --
 tests/Kconfig         |   15 ++
 tests/Makefile        |    1 
 tests/lkdtm.c         |  345 ++++++++++++++++++++++++++++++++++++++++++++++++++
 6 files changed, 361 insertions(+), 361 deletions(-)
drivers/misc/Makefile +0 -1
Index: linux-2.6.25-rc1/drivers/misc/Makefile
===================================================================
@@ -11,7 +11,6 @@ obj-$(CONFIG_ASUS_LAPTOP)     += asus-la
 obj-$(CONFIG_ATMEL_PWM)		+= atmel_pwm.o
 obj-$(CONFIG_ATMEL_SSC)		+= atmel-ssc.o
 obj-$(CONFIG_TC1100_WMI)	+= tc1100-wmi.o
-obj-$(CONFIG_LKDTM)		+= lkdtm.o
 obj-$(CONFIG_TIFM_CORE)       	+= tifm_core.o
 obj-$(CONFIG_TIFM_7XX1)       	+= tifm_7xx1.o
 obj-$(CONFIG_PHANTOM)		+= phantom.o
drivers/misc/lkdtm.c deleted +0 -345

345 lines not on this page · raw message

lib/Kconfig.debug +0 -15
Index: linux-2.6.25-rc1/lib/Kconfig.debug
===================================================================
@@ -490,21 +490,6 @@ config BACKTRACE_SELF_TEST
 
 	  Say N if you are unsure.
 
-config LKDTM
-	tristate "Linux Kernel Dump Test Tool Module"
-	depends on DEBUG_KERNEL
-	depends on KPROBES
-	default n
-	help
-	This module enables testing of the different dumping mechanisms by
-	inducing system failures at predefined crash points.
-	If you don't need it: say N
-	Choose M here to compile this code as a module. The module will be
-	called lkdtm.
-
-	Documentation on how to use the module can be found in
-	drivers/misc/lkdtm.c
-
 config FAULT_INJECTION
 	bool "Fault-injection framework"
 	depends on DEBUG_KERNEL
tests/Kconfig +15 -0
Index: linux-2.6.25-rc1/tests/Kconfig
===================================================================
@@ -37,4 +37,19 @@ config RT_MUTEX_TESTER
 	help
 	  This option enables a rt-mutex tester.
 
+config LKDTM
+	tristate "Linux Kernel Dump Test Tool Module"
+	depends on DEBUG_KERNEL
+	depends on KPROBES
+	default n
+	help
+	This module enables testing of the different dumping mechanisms by
+	inducing system failures at predefined crash points.
+	If you don't need it: say N
+	Choose M here to compile this code as a module. The module will be
+	called lkdtm.
+
+	Documentation on how to use the module can be found in
+	tests/lkdtm.c
+
 endif # KERNEL_TESTS
tests/Makefile +1 -0
Index: linux-2.6.25-rc1/tests/Makefile
===================================================================
@@ -5,3 +5,4 @@
 obj-$(CONFIG_DEBUG_LOCKING_API_SELFTESTS) += locking-selftest.o
 obj-$(CONFIG_RCU_TORTURE_TEST) += rcutorture.o
 obj-$(CONFIG_RT_MUTEX_TESTER) += rtmutex-tester.o
+obj-$(CONFIG_LKDTM) += lkdtm.o
tests/lkdtm.c new file +345 -0

345 lines not on this page · raw message

#6 lore raw

PATCH 6/8 Move kprobes smoke tests to tests/

In reply to Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move kprobe smoke tests to tests/

---
 kernel/test_kprobes.c |  228 --------------------------------------------------
 kernel/Makefile       |    1 
 lib/Kconfig.debug     |   12 --
 tests/Kconfig         |   12 ++
 tests/Makefile        |    1 
 tests/test_kprobes.c  |  228 ++++++++++++++++++++++++++++++++++++++++++++++++++
 6 files changed, 241 insertions(+), 241 deletions(-)
kernel/Makefile +0 -1
Index: linux-2.6.25-rc1/kernel/Makefile
===================================================================
@@ -47,7 +47,6 @@ obj-$(CONFIG_PID_NS) += pid_namespace.o
 obj-$(CONFIG_IKCONFIG) += configs.o
 obj-$(CONFIG_RESOURCE_COUNTERS) += res_counter.o
 obj-$(CONFIG_STOP_MACHINE) += stop_machine.o
-obj-$(CONFIG_KPROBES_SANITY_TEST) += test_kprobes.o
 obj-$(CONFIG_AUDIT) += audit.o auditfilter.o
 obj-$(CONFIG_AUDITSYSCALL) += auditsc.o
 obj-$(CONFIG_AUDIT_TREE) += audit_tree.o
kernel/test_kprobes.c deleted +0 -228

228 lines not on this page · raw message

lib/Kconfig.debug +0 -12
Index: linux-2.6.25-rc1/lib/Kconfig.debug
===================================================================
@@ -466,18 +466,6 @@ config BOOT_PRINTK_DELAY
 	  BOOT_PRINTK_DELAY also may cause DETECT_SOFTLOCKUP to detect
 	  what it believes to be lockup conditions.
 
-config KPROBES_SANITY_TEST
-	bool "Kprobes sanity tests"
-	depends on DEBUG_KERNEL
-	depends on KPROBES
-	default n
-	help
-	  This option provides for testing basic kprobes functionality on
-	  boot. A sample kprobe, jprobe and kretprobe are inserted and
-	  verified for functionality.
-
-	  Say N if you are unsure.
-
 config BACKTRACE_SELF_TEST
 	tristate "Self test for the backtrace code"
 	depends on DEBUG_KERNEL
tests/Kconfig +12 -0
Index: linux-2.6.25-rc1/tests/Kconfig
===================================================================
@@ -52,4 +52,16 @@ config LKDTM
 	Documentation on how to use the module can be found in
 	tests/lkdtm.c
 
+config KPROBES_SANITY_TEST
+	bool "Kprobes sanity tests"
+	depends on DEBUG_KERNEL
+	depends on KPROBES
+	default n
+	help
+	  This option provides for testing basic kprobes functionality on
+	  boot. A sample kprobe, jprobe and kretprobe are inserted and
+	  verified for functionality.
+
+	  Say N if you are unsure.
+
 endif # KERNEL_TESTS
tests/Makefile +1 -0
Index: linux-2.6.25-rc1/tests/Makefile
===================================================================
@@ -6,3 +6,4 @@ obj-$(CONFIG_DEBUG_LOCKING_API_SELFTESTS
 obj-$(CONFIG_RCU_TORTURE_TEST) += rcutorture.o
 obj-$(CONFIG_RT_MUTEX_TESTER) += rtmutex-tester.o
 obj-$(CONFIG_LKDTM) += lkdtm.o
+obj-$(CONFIG_KPROBES_SANITY_TEST) += test_kprobes.o
tests/test_kprobes.c new file +228 -0

228 lines not on this page · raw message

#7 lore raw

PATCH 7/8 Move backtrace tests to tests/

In reply to Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move backtrace selftests to tests/

---
 kernel/backtracetest.c |   48 ------------------------------------------------
 kernel/Makefile        |    1 -
 lib/Kconfig.debug      |   12 ------------
 tests/Kconfig          |   12 ++++++++++++
 tests/Makefile         |    1 +
 tests/backtracetest.c  |   48 ++++++++++++++++++++++++++++++++++++++++++++++++
 6 files changed, 61 insertions(+), 61 deletions(-)
kernel/Makefile +0 -1
Index: linux-2.6.25-rc1/kernel/Makefile
===================================================================
@@ -35,7 +35,6 @@ obj-$(CONFIG_KALLSYMS) += kallsyms.o
 obj-$(CONFIG_PM) += power/
 obj-$(CONFIG_BSD_PROCESS_ACCT) += acct.o
 obj-$(CONFIG_KEXEC) += kexec.o
-obj-$(CONFIG_BACKTRACE_SELF_TEST) += backtracetest.o
 obj-$(CONFIG_COMPAT) += compat.o
 obj-$(CONFIG_CGROUPS) += cgroup.o
 obj-$(CONFIG_CGROUP_DEBUG) += cgroup_debug.o
kernel/backtracetest.c deleted +0 -48

48 lines not on this page · raw message

lib/Kconfig.debug +0 -12
Index: linux-2.6.25-rc1/lib/Kconfig.debug
===================================================================
@@ -466,18 +466,6 @@ config BOOT_PRINTK_DELAY
 	  BOOT_PRINTK_DELAY also may cause DETECT_SOFTLOCKUP to detect
 	  what it believes to be lockup conditions.
 
-config BACKTRACE_SELF_TEST
-	tristate "Self test for the backtrace code"
-	depends on DEBUG_KERNEL
-	default n
-	help
-	  This option provides a kernel module that can be used to test
-	  the kernel stack backtrace code. This option is not useful
-	  for distributions or general kernels, but only for kernel
-	  developers working on architecture code.
-
-	  Say N if you are unsure.
-
 config FAULT_INJECTION
 	bool "Fault-injection framework"
 	depends on DEBUG_KERNEL
tests/Kconfig +12 -0
Index: linux-2.6.25-rc1/tests/Kconfig
===================================================================
@@ -64,4 +64,16 @@ config KPROBES_SANITY_TEST
 
 	  Say N if you are unsure.
 
+config BACKTRACE_SELF_TEST
+	tristate "Self test for the backtrace code"
+	depends on DEBUG_KERNEL
+	default n
+	help
+	  This option provides a kernel module that can be used to test
+	  the kernel stack backtrace code. This option is not useful
+	  for distributions or general kernels, but only for kernel
+	  developers working on architecture code.
+
+	  Say N if you are unsure.
+
 endif # KERNEL_TESTS
tests/Makefile +1 -0
Index: linux-2.6.25-rc1/tests/Makefile
===================================================================
@@ -7,3 +7,4 @@ obj-$(CONFIG_RCU_TORTURE_TEST) += rcutor
 obj-$(CONFIG_RT_MUTEX_TESTER) += rtmutex-tester.o
 obj-$(CONFIG_LKDTM) += lkdtm.o
 obj-$(CONFIG_KPROBES_SANITY_TEST) += test_kprobes.o
+obj-$(CONFIG_BACKTRACE_SELF_TEST) += backtracetest.o
tests/backtracetest.c new file +48 -0

48 lines not on this page · raw message

Acked-by on v1 7/8
#8 lore raw

Re: [PATCH 7/8] Move backtrace tests to tests/

Quoted 5 lines · On Mon, 11 Feb 2008 16:21:45 +0530 Ananth N Mavinakayanahalli…

From: Ananth N Mavinakayanahalli <[email protected]>

Move backtrace selftests to tests/

Thanks for doing this work!

Signature · 3 lines
If you want to reach me at my work email, use [email protected]
For development, discussion and tips for power savings, 
visit http://www.lesswatts.org
#9 lore raw

PATCH 8/8 Move RODATA and NX tests to tests/

In reply to Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move RODATA and NX testcases to tests/

---
 arch/x86/kernel/test_nx.c     |  173 ------------------------------------------
 arch/x86/kernel/test_rodata.c |   86 --------------------
 arch/x86/Kconfig.debug        |   16 ---
 arch/x86/kernel/Makefile      |    2 
 tests/Kconfig                 |   16 +++
 tests/Makefile                |    2 
 tests/test_nx.c               |  173 ++++++++++++++++++++++++++++++++++++++++++
 tests/test_rodata.c           |   86 ++++++++++++++++++++
 8 files changed, 277 insertions(+), 277 deletions(-)
arch/x86/Kconfig.debug +0 -16
Index: linux-2.6.25-rc1/arch/x86/Kconfig.debug
===================================================================
@@ -64,22 +64,6 @@ config DEBUG_RODATA
 	  data. This is recommended so that we can catch kernel bugs sooner.
 	  If in doubt, say "Y".
 
-config DEBUG_RODATA_TEST
-	bool "Testcase for the DEBUG_RODATA feature"
-	depends on DEBUG_RODATA
-	help
-	  This option enables a testcase for the DEBUG_RODATA
-	  feature as well as for the change_page_attr() infrastructure.
-	  If in doubt, say "N"
-
-config DEBUG_NX_TEST
-	tristate "Testcase for the NX non-executable stack feature"
-	depends on DEBUG_KERNEL && m
-	help
-	  This option enables a testcase for the CPU NX capability
-	  and the software setup of this feature.
-	  If in doubt, say "N"
-
 config 4KSTACKS
 	bool "Use 4Kb for kernel stacks instead of 8Kb"
 	depends on DEBUG_KERNEL
arch/x86/kernel/Makefile +0 -2
Index: linux-2.6.25-rc1/arch/x86/kernel/Makefile
===================================================================
@@ -65,8 +65,6 @@ obj-$(CONFIG_HPET_TIMER) 	+= hpet.o
 
 obj-$(CONFIG_K8_NB)		+= k8.o
 obj-$(CONFIG_MGEODE_LX)		+= geode_32.o mfgpt_32.o
-obj-$(CONFIG_DEBUG_RODATA_TEST)	+= test_rodata.o
-obj-$(CONFIG_DEBUG_NX_TEST)	+= test_nx.o
 
 obj-$(CONFIG_VMI)		+= vmi_32.o vmiclock_32.o
 obj-$(CONFIG_PARAVIRT)		+= paravirt.o paravirt_patch_$(BITS).o
arch/x86/kernel/test_nx.c deleted +0 -173

173 lines not on this page · raw message

arch/x86/kernel/test_rodata.c deleted +0 -86

86 lines not on this page · raw message

tests/Kconfig +16 -0
Index: linux-2.6.25-rc1/tests/Kconfig
===================================================================
@@ -76,4 +76,20 @@ config BACKTRACE_SELF_TEST
 
 	  Say N if you are unsure.
 
+config DEBUG_RODATA_TEST
+	bool "Testcase for the DEBUG_RODATA feature"
+	depends on X86 && DEBUG_RODATA
+	help
+	  This option enables a testcase for the DEBUG_RODATA
+	  feature as well as for the change_page_attr() infrastructure.
+	  If in doubt, say "N"
+
+config DEBUG_NX_TEST
+	tristate "Testcase for the NX non-executable stack feature"
+	depends on X86 && DEBUG_KERNEL && m
+	help
+	  This option enables a testcase for the CPU NX capability
+	  and the software setup of this feature.
+	  If in doubt, say "N"
+
 endif # KERNEL_TESTS
tests/Makefile +2 -0
Index: linux-2.6.25-rc1/tests/Makefile
===================================================================
@@ -8,3 +8,5 @@ obj-$(CONFIG_RT_MUTEX_TESTER) += rtmutex
 obj-$(CONFIG_LKDTM) += lkdtm.o
 obj-$(CONFIG_KPROBES_SANITY_TEST) += test_kprobes.o
 obj-$(CONFIG_BACKTRACE_SELF_TEST) += backtracetest.o
+obj-$(CONFIG_DEBUG_RODATA_TEST)	+= test_rodata.o
+obj-$(CONFIG_DEBUG_NX_TEST) += test_nx.o
tests/test_nx.c new file +173 -0

173 lines not on this page · raw message

tests/test_rodata.c new file +86 -0

86 lines not on this page · raw message

#10 lore raw

Re: [PATCH 8/8] Move RODATA and NX tests to tests/

Quoted 3 lines · Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move RODATA and NX testcases to tests/

i'm not sure this is the proper place for it - it's highly x86 specific. arch/x86/tests sounds like the better place for it.

Ingo

#11 lore raw

Re: [PATCH 8/8] Move RODATA and NX tests to tests/

Quoted 9 lines · Ingo Molnar
Quoted 3 lines · Ananth N Mavinakayanahalli

From: Ananth N Mavinakayanahalli <[email protected]>

Move RODATA and NX testcases to tests/

i'm not sure this is the proper place for it - it's highly x86 specific. arch/x86/tests sounds like the better place for it.

Right. I wasn't sure of it and so made these depend on CONFIG_X86. But yes, it makes more sense for them to live someplace arch specific.

Ananth

#12 lore raw

Re: [PATCH 8/8] Move RODATA and NX tests to tests/

In reply to Ananth N Mavinakayanahalli
Quoted 4 lines · On Mon, 11 Feb 2008 16:22:29 +0530 Ananth N Mavinakayanahalli…

From: Ananth N Mavinakayanahalli <[email protected]>

Move RODATA and NX testcases to tests/

for the NX test I can see this; for RODATA...
that one is not really stand alone, but integrated with the rest of the rodata code.

Signature · 3 lines
If you want to reach me at my work email, use [email protected]
For development, discussion and tips for power savings, 
visit http://www.lesswatts.org
#13 lore raw
In reply to Ananth N Mavinakayanahalli
Quoted 6 lines · On Mon, 11 Feb 2008 16:14:52 +0530 Ananth N Mavinakayanahalli wrote:

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

Hi,

As Linus wrote on a recent sh pull request:

"Please use "git diff -M --stat --summary" to generate the diffstat: the -M enables rename detection, and the summary enables a summary of new/deleted or renamed files."

---
~Randy

#14 lore raw
Quoted 9 lines · On Mon, 11 Feb 2008 10:26:49 -0800 Randy Dunlap wrote:
Quoted 6 lines · On Mon, 11 Feb 2008 16:14:52 +0530 Ananth N Mavinakayanahalli wrote:

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

Quoted 7 lines

Hi,

As Linus wrote on a recent sh pull request:

"Please use "git diff -M --stat --summary" to generate the diffstat: the -M enables rename detection, and the summary enables a summary of new/deleted or renamed files."

Argh, you probably didn't use git, so please ignore my comment.

---
~Randy

#15 lore raw
In reply to Ananth N Mavinakayanahalli
Quoted 6 lines · Ananth N Mavinakayanahalli

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

ACK to patches 1-7, and I agree with Ingo that the x86-specific test should stay under arch/x86.

maintainer
#16 lore raw
Quoted 10 lines · On Tue, 12 Feb 2008 11:44:52 -0500 Christoph Hellwig <[email protected]> wrote:
Quoted 6 lines · Ananth N Mavinakayanahalli

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

ACK to patches 1-7, and I agree with Ingo that the x86-specific test should stay under arch/x86.

OK. But now is basically the worst time for me (or anyone else) to merge large code-motion changes like this, because they need to be carried for two months or more.

And even though git can track renames, putting them into a git tree (say, git-kbuild) won't help, because if some other git tree tries to modify a file in its original place, I get to fix up the fallout.

Which I _could_ do, and would do if the patches were particularly risky or added/changed functionality or whatever. But they don't do that, and there is little advantage in maintaining them for the >2 months.

So. Please redo and resend the patches when we hit 2.6.25-rc6 or so?

Thanks.

(linux-next will largely fix all this: git will take care of the renames and I'll just base the -mm queue on the consolidated linux-next. But we aren't there yet).

#17 lore raw
Quoted 8 lines · Andrew Morton
Quoted 5 lines · On Tue, 12 Feb 2008 11:44:52 -0500 Christoph Hellwig <[email protected]> wrote:
Quoted 4 lines · Ananth N Mavinakayanahalli

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

Quoted 9 lines
Quoted 4 lines
Quoted 2 lines

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

ACK to patches 1-7, and I agree with Ingo that the x86-specific test should stay under arch/x86.

OK. But now is basically the worst time for me (or anyone else) to merge large code-motion changes like this, because they need to be carried for two months or more.

alternatively, since it's just code motion and nothing more, it could just be done in 2.6.25-rc; in fact doing motion patches in the -rc2 window makes sense to me, that's the point where all external trees are the smallest, and it should be provably the same result.. so safe.

#18 lore raw
In reply to Andrew Morton

Hi Linus.

Will you consider such a primary code-movement for -rc1 or shall we wait until next merge window?

Had we hit -rc2 I would not have sent this pull req and feel free to flame me anyway.

The rationale to get it merged is obviously to avoid merge conflicts and the only reason I ask is that I consider it a low risk patch.

I have not included 8/8 since it was questioned and it will wait until next merge window. But the first 7 was straightforward.

You can pull from:
ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/tests.git

diffstat and shortlog below.
I also included mail last with a few of the merge related comments.

Sam

 Makefile                                        |    1 +
 drivers/misc/Makefile                           |    1 -
 kernel/Makefile                                 |    4 -
 lib/Kconfig.debug                               |   71 +--------------------
 lib/Makefile                                    |    1 -
 tests/Kconfig                                   |   79 +++++++++++++++++++++++
 tests/Makefile                                  |   10 +++
 {kernel => tests}/backtracetest.c               |    0 
 {drivers/misc => tests}/lkdtm.c                 |   12 ++--
 {lib => tests}/locking-selftest-hardirq.h       |    0 
 {lib => tests}/locking-selftest-mutex.h         |    0 
 {lib => tests}/locking-selftest-rlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-rlock-softirq.h |    0 
 {lib => tests}/locking-selftest-rlock.h         |    0 
 {lib => tests}/locking-selftest-rsem.h          |    0 
 {lib => tests}/locking-selftest-softirq.h       |    0 
 {lib => tests}/locking-selftest-spin-hardirq.h  |    0 
 {lib => tests}/locking-selftest-spin-softirq.h  |    0 
 {lib => tests}/locking-selftest-spin.h          |    0 
 {lib => tests}/locking-selftest-wlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-wlock-softirq.h |    0 
 {lib => tests}/locking-selftest-wlock.h         |    0 
 {lib => tests}/locking-selftest-wsem.h          |    0 
 {lib => tests}/locking-selftest.c               |    0 
 {kernel => tests}/rcutorture.c                  |    0 
 {kernel => tests}/rtmutex-tester.c              |    2 +-
 {kernel => tests}/test_kprobes.c                |    0 
 27 files changed, 99 insertions(+), 82 deletions(-)

Ananth N Mavinakayanahalli (7):
Create tests/ directory
Move locking selftests to tests/
Move rcutorture to tests/
Move rtmutex-tests to tests/
Move lkdtm to tests/
Move kprobes smoke tests to tests/
Move backtrace tests to tests/

Quoted 34 lines · Andrew Morton
Quoted 10 lines · On Tue, 12 Feb 2008 11:44:52 -0500 Christoph Hellwig <[email protected]> wrote:
Quoted 6 lines · Ananth N Mavinakayanahalli

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

ACK to patches 1-7, and I agree with Ingo that the x86-specific test should stay under arch/x86.

OK. But now is basically the worst time for me (or anyone else) to merge large code-motion changes like this, because they need to be carried for two months or more.

And even though git can track renames, putting them into a git tree (say, git-kbuild) won't help, because if some other git tree tries to modify a file in its original place, I get to fix up the fallout.

Which I _could_ do, and would do if the patches were particularly risky or added/changed functionality or whatever. But they don't do that, and there is little advantage in maintaining them for the >2 months.

So. Please redo and resend the patches when we hit 2.6.25-rc6 or so?

Thanks.

(linux-next will largely fix all this: git will take care of the renames and I'll just base the -mm queue on the consolidated linux-next. But we aren't there yet).

#19 lore raw
Quoted 22 lines · Sam Ravnborg

Hi Linus.

Will you consider such a primary code-movement for -rc1 or shall we wait until next merge window?

Had we hit -rc2 I would not have sent this pull req and feel free to flame me anyway.

The rationale to get it merged is obviously to avoid merge conflicts and the only reason I ask is that I consider it a low risk patch.

I have not included 8/8 since it was questioned and it will wait until next merge window. But the first 7 was straightforward.

You can pull from:
ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/tests.git

diffstat and shortlog below.
I also included mail last with a few of the merge related comments.

Quoted 8 lines

Sam

 Makefile                                        |    1 +
 drivers/misc/Makefile                           |    1 -
 kernel/Makefile                                 |    4 -
 lib/Kconfig.debug                               |   71 +--------------------
 lib/Makefile                                    |    1 -
 tests/Kconfig                                   |   79 +++++++++++++++++++++++

we could make it even lower risk and not move the Kconfig now. Moving the Kconfig is fine for .26; it doesn't really impact anything else

Acked-by
#20 lore raw
In reply to Sam Ravnborg
Quoted 13 lines · Sam Ravnborg
 {kernel => tests}/backtracetest.c               |    0 
 {drivers/misc => tests}/lkdtm.c                 |   12 ++--
 {lib => tests}/locking-selftest-hardirq.h       |    0 
 {lib => tests}/locking-selftest-mutex.h         |    0 
 {lib => tests}/locking-selftest-rlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-rlock-softirq.h |    0 
 {lib => tests}/locking-selftest-rlock.h         |    0 
 {lib => tests}/locking-selftest-rsem.h          |    0 
 {lib => tests}/locking-selftest-softirq.h       |    0 
 {lib => tests}/locking-selftest-spin-hardirq.h  |    0 
 {lib => tests}/locking-selftest-spin-softirq.h  |    0 
 {lib => tests}/locking-selftest-spin.h          |    0 
 {lib => tests}/locking-selftest-wlock-hardirq.h |    0 
Quoted 8 lines
 {lib => tests}/locking-selftest-wlock-softirq.h |    0 
 {lib => tests}/locking-selftest-wlock.h         |    0 
 {lib => tests}/locking-selftest-wsem.h          |    0 
 {lib => tests}/locking-selftest.c               |    0 
 {kernel => tests}/rcutorture.c                  |    0 
 {kernel => tests}/rtmutex-tester.c              |    2 +-
 {kernel => tests}/test_kprobes.c                |    0 
 27 files changed, 99 insertions(+), 82 deletions(-)

Ingo

#21 lore raw
In reply to Sam Ravnborg

Hi Anath.

Linus did not pull this in the -rc1 to -rc2 timeframe so please resubmit the patch serie one week into the next merge window (when most of the trees has hit linus' tree and Andrew has made his first merge).

IF you need an extra eye balling then you can submit a few weeks before the merge window opens. Thats typical after an -rc with only a few patches.

Thanks,
Sam

Quoted 104 lines · Sam Ravnborg

Hi Linus.

Will you consider such a primary code-movement for -rc1 or shall we wait until next merge window?

Had we hit -rc2 I would not have sent this pull req and feel free to flame me anyway.

The rationale to get it merged is obviously to avoid merge conflicts and the only reason I ask is that I consider it a low risk patch.

I have not included 8/8 since it was questioned and it will wait until next merge window. But the first 7 was straightforward.

You can pull from:
ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/tests.git

diffstat and shortlog below.
I also included mail last with a few of the merge related comments.

Sam

 Makefile                                        |    1 +
 drivers/misc/Makefile                           |    1 -
 kernel/Makefile                                 |    4 -
 lib/Kconfig.debug                               |   71 +--------------------
 lib/Makefile                                    |    1 -
 tests/Kconfig                                   |   79 +++++++++++++++++++++++
 tests/Makefile                                  |   10 +++
 {kernel => tests}/backtracetest.c               |    0 
 {drivers/misc => tests}/lkdtm.c                 |   12 ++--
 {lib => tests}/locking-selftest-hardirq.h       |    0 
 {lib => tests}/locking-selftest-mutex.h         |    0 
 {lib => tests}/locking-selftest-rlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-rlock-softirq.h |    0 
 {lib => tests}/locking-selftest-rlock.h         |    0 
 {lib => tests}/locking-selftest-rsem.h          |    0 
 {lib => tests}/locking-selftest-softirq.h       |    0 
 {lib => tests}/locking-selftest-spin-hardirq.h  |    0 
 {lib => tests}/locking-selftest-spin-softirq.h  |    0 
 {lib => tests}/locking-selftest-spin.h          |    0 
 {lib => tests}/locking-selftest-wlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-wlock-softirq.h |    0 
 {lib => tests}/locking-selftest-wlock.h         |    0 
 {lib => tests}/locking-selftest-wsem.h          |    0 
 {lib => tests}/locking-selftest.c               |    0 
 {kernel => tests}/rcutorture.c                  |    0 
 {kernel => tests}/rtmutex-tester.c              |    2 +-
 {kernel => tests}/test_kprobes.c                |    0 
 27 files changed, 99 insertions(+), 82 deletions(-)

Ananth N Mavinakayanahalli (7):
Create tests/ directory
Move locking selftests to tests/
Move rcutorture to tests/
Move rtmutex-tests to tests/
Move lkdtm to tests/
Move kprobes smoke tests to tests/
Move backtrace tests to tests/

Quoted 26 lines · Andrew Morton
Quoted 10 lines · On Tue, 12 Feb 2008 11:44:52 -0500 Christoph Hellwig <[email protected]> wrote:
Quoted 6 lines · Ananth N Mavinakayanahalli

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

ACK to patches 1-7, and I agree with Ingo that the x86-specific test should stay under arch/x86.

OK. But now is basically the worst time for me (or anyone else) to merge large code-motion changes like this, because they need to be carried for two months or more.

And even though git can track renames, putting them into a git tree (say, git-kbuild) won't help, because if some other git tree tries to modify a file in its original place, I get to fix up the fallout.

Which I _could_ do, and would do if the patches were particularly risky or added/changed functionality or whatever. But they don't do that, and there is little advantage in maintaining them for the >2 months.

Quoted 8 lines

So. Please redo and resend the patches when we hit 2.6.25-rc6 or so?

Thanks.

(linux-next will largely fix all this: git will take care of the renames and I'll just base the -mm queue on the consolidated linux-next. But we aren't there yet).

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#22 lore raw
Quoted 1 line · Sam Ravnborg

Hi Anath.

Hi Sam,

Quoted 4 lines

Linus did not pull this in the -rc1 to -rc2 timeframe so please resubmit the patch serie one week into the next merge window (when most of the trees has hit linus' tree and Andrew has made his first merge).

Isn't this set a good candidate for linux-next? If so, we could request Stephen to pull in the patchset.

Ananth

Quoted 112 lines

IF you need an extra eye balling then you can submit a few weeks before the merge window opens. Thats typical after an -rc with only a few patches.

Thanks,
Sam

Quoted 104 lines · Sam Ravnborg

Hi Linus.

Will you consider such a primary code-movement for -rc1 or shall we wait until next merge window?

Had we hit -rc2 I would not have sent this pull req and feel free to flame me anyway.

The rationale to get it merged is obviously to avoid merge conflicts and the only reason I ask is that I consider it a low risk patch.

I have not included 8/8 since it was questioned and it will wait until next merge window. But the first 7 was straightforward.

You can pull from:
ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/tests.git

diffstat and shortlog below.
I also included mail last with a few of the merge related comments.

Sam

 Makefile                                        |    1 +
 drivers/misc/Makefile                           |    1 -
 kernel/Makefile                                 |    4 -
 lib/Kconfig.debug                               |   71 +--------------------
 lib/Makefile                                    |    1 -
 tests/Kconfig                                   |   79 +++++++++++++++++++++++
 tests/Makefile                                  |   10 +++
 {kernel => tests}/backtracetest.c               |    0 
 {drivers/misc => tests}/lkdtm.c                 |   12 ++--
 {lib => tests}/locking-selftest-hardirq.h       |    0 
 {lib => tests}/locking-selftest-mutex.h         |    0 
 {lib => tests}/locking-selftest-rlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-rlock-softirq.h |    0 
 {lib => tests}/locking-selftest-rlock.h         |    0 
 {lib => tests}/locking-selftest-rsem.h          |    0 
 {lib => tests}/locking-selftest-softirq.h       |    0 
 {lib => tests}/locking-selftest-spin-hardirq.h  |    0 
 {lib => tests}/locking-selftest-spin-softirq.h  |    0 
 {lib => tests}/locking-selftest-spin.h          |    0 
 {lib => tests}/locking-selftest-wlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-wlock-softirq.h |    0 
 {lib => tests}/locking-selftest-wlock.h         |    0 
 {lib => tests}/locking-selftest-wsem.h          |    0 
 {lib => tests}/locking-selftest.c               |    0 
 {kernel => tests}/rcutorture.c                  |    0 
 {kernel => tests}/rtmutex-tester.c              |    2 +-
 {kernel => tests}/test_kprobes.c                |    0 
 27 files changed, 99 insertions(+), 82 deletions(-)

Ananth N Mavinakayanahalli (7):
Create tests/ directory
Move locking selftests to tests/
Move rcutorture to tests/
Move rtmutex-tests to tests/
Move lkdtm to tests/
Move kprobes smoke tests to tests/
Move backtrace tests to tests/

Quoted 26 lines · Andrew Morton
Quoted 10 lines · On Tue, 12 Feb 2008 11:44:52 -0500 Christoph Hellwig <[email protected]> wrote:
Quoted 6 lines · Ananth N Mavinakayanahalli

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

ACK to patches 1-7, and I agree with Ingo that the x86-specific test should stay under arch/x86.

OK. But now is basically the worst time for me (or anyone else) to merge large code-motion changes like this, because they need to be carried for two months or more.

And even though git can track renames, putting them into a git tree (say, git-kbuild) won't help, because if some other git tree tries to modify a file in its original place, I get to fix up the fallout.

Which I _could_ do, and would do if the patches were particularly risky or added/changed functionality or whatever. But they don't do that, and there is little advantage in maintaining them for the >2 months.

Quoted 8 lines

So. Please redo and resend the patches when we hit 2.6.25-rc6 or so?

Thanks.

(linux-next will largely fix all this: git will take care of the renames and I'll just base the -mm queue on the consolidated linux-next. But we aren't there yet).

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#23 lore raw
In reply to Sam Ravnborg
Quoted 10 lines · Sam Ravnborg

Hi Anath.

Linus did not pull this in the -rc1 to -rc2 timeframe so please resubmit the patch serie one week into the next merge window (when most of the trees has hit linus' tree and Andrew has made his first merge).

IF you need an extra eye balling then you can submit a few weeks before the merge window opens. Thats typical after an -rc with only a few patches.

Stephen,

The patchset in question is just a major code movement - basically to move all in-kernel tests to live under a toplevel tests/ directory. As such, all the stakeholders have acked the patchset, but it does look like this is a big enough change to be deferred to the next merge window.

Given that there is general agreement about the patchset, could you please pull in the changes into the linux-next tree?

Sam has setup a git tree for this and you can pull from:
ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/tests.git

Link to the thread: http://lkml.org/lkml/2008/2/11/97

Thanks,
Ananth

Quoted 108 lines

Thanks,
Sam

Quoted 104 lines · Sam Ravnborg

Hi Linus.

Will you consider such a primary code-movement for -rc1 or shall we wait until next merge window?

Had we hit -rc2 I would not have sent this pull req and feel free to flame me anyway.

The rationale to get it merged is obviously to avoid merge conflicts and the only reason I ask is that I consider it a low risk patch.

I have not included 8/8 since it was questioned and it will wait until next merge window. But the first 7 was straightforward.

You can pull from:
ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/tests.git

diffstat and shortlog below.
I also included mail last with a few of the merge related comments.

Sam

 Makefile                                        |    1 +
 drivers/misc/Makefile                           |    1 -
 kernel/Makefile                                 |    4 -
 lib/Kconfig.debug                               |   71 +--------------------
 lib/Makefile                                    |    1 -
 tests/Kconfig                                   |   79 +++++++++++++++++++++++
 tests/Makefile                                  |   10 +++
 {kernel => tests}/backtracetest.c               |    0 
 {drivers/misc => tests}/lkdtm.c                 |   12 ++--
 {lib => tests}/locking-selftest-hardirq.h       |    0 
 {lib => tests}/locking-selftest-mutex.h         |    0 
 {lib => tests}/locking-selftest-rlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-rlock-softirq.h |    0 
 {lib => tests}/locking-selftest-rlock.h         |    0 
 {lib => tests}/locking-selftest-rsem.h          |    0 
 {lib => tests}/locking-selftest-softirq.h       |    0 
 {lib => tests}/locking-selftest-spin-hardirq.h  |    0 
 {lib => tests}/locking-selftest-spin-softirq.h  |    0 
 {lib => tests}/locking-selftest-spin.h          |    0 
 {lib => tests}/locking-selftest-wlock-hardirq.h |    0 
 {lib => tests}/locking-selftest-wlock-softirq.h |    0 
 {lib => tests}/locking-selftest-wlock.h         |    0 
 {lib => tests}/locking-selftest-wsem.h          |    0 
 {lib => tests}/locking-selftest.c               |    0 
 {kernel => tests}/rcutorture.c                  |    0 
 {kernel => tests}/rtmutex-tester.c              |    2 +-
 {kernel => tests}/test_kprobes.c                |    0 
 27 files changed, 99 insertions(+), 82 deletions(-)

Ananth N Mavinakayanahalli (7):
Create tests/ directory
Move locking selftests to tests/
Move rcutorture to tests/
Move rtmutex-tests to tests/
Move lkdtm to tests/
Move kprobes smoke tests to tests/
Move backtrace tests to tests/

Quoted 26 lines · Andrew Morton
Quoted 10 lines · On Tue, 12 Feb 2008 11:44:52 -0500 Christoph Hellwig <[email protected]> wrote:
Quoted 6 lines · Ananth N Mavinakayanahalli

The following series of patches create and populate the toplevel tests/ directory. This will henceforth be the place where all in-kernel tests live.

All patches against 2.6.25-rc1 and are just code movement without any change in functionality.

ACK to patches 1-7, and I agree with Ingo that the x86-specific test should stay under arch/x86.

OK. But now is basically the worst time for me (or anyone else) to merge large code-motion changes like this, because they need to be carried for two months or more.

And even though git can track renames, putting them into a git tree (say, git-kbuild) won't help, because if some other git tree tries to modify a file in its original place, I get to fix up the fallout.

Which I _could_ do, and would do if the patches were particularly risky or added/changed functionality or whatever. But they don't do that, and there is little advantage in maintaining them for the >2 months.

Quoted 8 lines

So. Please redo and resend the patches when we hit 2.6.25-rc6 or so?

Thanks.

(linux-next will largely fix all this: git will take care of the renames and I'll just base the -mm queue on the consolidated linux-next. But we aren't there yet).

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#24 lore raw

Hi Ananth,

Quoted 7 lines · On Fri, 22 Feb 2008 09:12:31 +0530 Ananth N Mavinakayanahalli…

The patchset in question is just a major code movement - basically to move all in-kernel tests to live under a toplevel tests/ directory. As such, all the stakeholders have acked the patchset, but it does look like this is a big enough change to be deferred to the next merge window.

Quoted 7 lines

Given that there is general agreement about the patchset, could you please pull in the changes into the linux-next tree?

Sam has setup a git tree for this and you can pull from:
ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/tests.git

Link to the thread: http://lkml.org/lkml/2008/2/11/97

I will include this in the next linux-tree. It looks like it should not cause to many problems (it merges OK on top of the about to be announce next-20080222), but if I get a hard to resolve merge problem with it, I will drop it first, OK.

I have noted you as the contact.

Signature · 2 lines
Cheers,
Stephen Rothwell                    [email protected]
#25 lore raw
Quoted 16 lines · Stephen Rothwell

Hi Ananth,

Quoted 13 lines · On Fri, 22 Feb 2008 09:12:31 +0530 Ananth N Mavinakayanahalli…

The patchset in question is just a major code movement - basically to move all in-kernel tests to live under a toplevel tests/ directory. As such, all the stakeholders have acked the patchset, but it does look like this is a big enough change to be deferred to the next merge window.

Given that there is general agreement about the patchset, could you please pull in the changes into the linux-next tree?

Sam has setup a git tree for this and you can pull from:
ssh://master.kernel.org/pub/scm/linux/kernel/git/sam/tests.git

Quoted 8 lines
Quoted 1 line

Link to the thread: http://lkml.org/lkml/2008/2/11/97

I will include this in the next linux-tree. It looks like it should not cause to many problems (it merges OK on top of the about to be announce next-20080222), but if I get a hard to resolve merge problem with it, I will drop it first, OK.

I have noted you as the contact.

Sure! Thanks Stephen.

Ananth