aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/net/test_bpf.sh
diff options
context:
space:
mode:
authorShuah Khan <shuahkh@osg.samsung.com>2014-10-30 16:52:15 -0600
committerShuah Khan <shuahkh@osg.samsung.com>2014-11-05 08:12:40 -0700
commit7069a97a14155349545c73084f9f9f6b6380e0f7 (patch)
tree268bc9eadb12c3817885e4920989436a5025c6ba /tools/testing/selftests/net/test_bpf.sh
parentLinux 3.18-rc3 (diff)
downloadlinux-dev-7069a97a14155349545c73084f9f9f6b6380e0f7.tar.xz
linux-dev-7069a97a14155349545c73084f9f9f6b6380e0f7.zip
selftests/net: move test out of Makefile into a shell script
Currently bpf test run from the Makefile. Move it out of the Makefile to be run from a shell script to allow the test to be run as stand-alone test, in addition to allowing the test run from a make target. Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com> Acked-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'tools/testing/selftests/net/test_bpf.sh')
-rwxr-xr-xtools/testing/selftests/net/test_bpf.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/tools/testing/selftests/net/test_bpf.sh b/tools/testing/selftests/net/test_bpf.sh
new file mode 100755
index 000000000000..8b29796d46aa
--- /dev/null
+++ b/tools/testing/selftests/net/test_bpf.sh
@@ -0,0 +1,10 @@
+#!/bin/sh
+# Runs bpf test using test_bpf kernel module
+
+if /sbin/modprobe -q test_bpf ; then
+ /sbin/modprobe -q -r test_bpf;
+ echo "test_bpf: ok";
+else
+ echo "test_bpf: [FAIL]";
+ exit 1;
+fi