aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/user
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-12-16 13:15:12 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2014-12-16 13:15:12 -0800
commit61de8e53640ceeda564a65170a46c1edc2b37e11 (patch)
treef5b28f510ba8b6515fbdf67a4d81eccdeae742f5 /tools/testing/selftests/user
parentMerge tag 'trace-3.19-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace (diff)
parentselftest: size: Add size test for Linux kernel (diff)
downloadlinux-dev-61de8e53640ceeda564a65170a46c1edc2b37e11.tar.xz
linux-dev-61de8e53640ceeda564a65170a46c1edc2b37e11.zip
Merge tag 'linux-kselftest-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest
Pull kselftest update from Shuah Khan: "kselftest updates for 3.19-rc1: - kcmp test include file cleanup - kcmp change to build on all architectures - A light weight kselftest framework that provides a set of interfaces for tests to use to report results. In addition, several tests are updated to use the framework. - A new runtime system size test that prints the amount of RAM that the currently running system is using" * tag 'linux-kselftest-3.19-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/shuah/linux-kselftest: selftest: size: Add size test for Linux kernel selftests/kcmp: Always try to build the test selftests/kcmp: Don't include kernel headers kcmp: Move kcmp.h into uapi selftests/timers: change test to use ksft framework selftests/kcmp: change test to use ksft framework selftests/ipc: change test to use ksft framework selftests/breakpoints: change test to use ksft framework selftests: add kselftest framework for uniform test reporting selftests/user: move test out of Makefile into a shell script selftests/net: move test out of Makefile into a shell script
Diffstat (limited to 'tools/testing/selftests/user')
-rw-r--r--tools/testing/selftests/user/Makefile8
-rwxr-xr-xtools/testing/selftests/user/test_user_copy.sh10
2 files changed, 11 insertions, 7 deletions
diff --git a/tools/testing/selftests/user/Makefile b/tools/testing/selftests/user/Makefile
index 396255bd720e..12c9d15bab07 100644
--- a/tools/testing/selftests/user/Makefile
+++ b/tools/testing/selftests/user/Makefile
@@ -4,10 +4,4 @@
all:
run_tests: all
- @if /sbin/modprobe test_user_copy ; then \
- rmmod test_user_copy; \
- echo "user_copy: ok"; \
- else \
- echo "user_copy: [FAIL]"; \
- exit 1; \
- fi
+ ./test_user_copy.sh
diff --git a/tools/testing/selftests/user/test_user_copy.sh b/tools/testing/selftests/user/test_user_copy.sh
new file mode 100755
index 000000000000..350107f40c1d
--- /dev/null
+++ b/tools/testing/selftests/user/test_user_copy.sh
@@ -0,0 +1,10 @@
+#!/bin/sh
+# Runs copy_to/from_user infrastructure using test_user_copy kernel module
+
+if /sbin/modprobe -q test_user_copy; then
+ /sbin/modprobe -q -r test_user_copy
+ echo "user_copy: ok"
+else
+ echo "user_copy: [FAIL]"
+ exit 1
+fi