diff options
author | Dengke Du <dengke.du@windriver.com> | 2018-08-17 17:33:01 -0700 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2018-08-19 16:09:28 -0700 |
commit | e88b38a9d214c3296892e0e6f6c6b444d1d48a54 (patch) | |
tree | 1308de05838d3780a0628cddf4af98ece21db85b /meta-oe | |
parent | afb81129061d7d856ed88fce8cc052e01770c7cd (diff) | |
download | meta-openembedded-e88b38a9d214c3296892e0e6f6c6b444d1d48a54.tar.gz |
kernel-selftest: add ptest support
Group the kernel-selftest testcases in run-ptest.
Signed-off-by: Dengke Du <dengke.du@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-oe')
-rw-r--r-- | meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb | 4 | ||||
-rwxr-xr-x | meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/run-ptest | 11 |
2 files changed, 14 insertions, 1 deletions
diff --git a/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb b/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb index 220250c33..f407d077b 100644 --- a/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb +++ b/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest.bb | |||
@@ -10,6 +10,8 @@ DEPENDS = "rsync-native" | |||
10 | SRC_URI_libc-musl += "file://userfaultfd.patch \ | 10 | SRC_URI_libc-musl += "file://userfaultfd.patch \ |
11 | file://0001-bpf-test_progs.c-add-support-for-musllibc.patch \ | 11 | file://0001-bpf-test_progs.c-add-support-for-musllibc.patch \ |
12 | " | 12 | " |
13 | SRC_URI += "file://run-ptest \ | ||
14 | " | ||
13 | 15 | ||
14 | # now we just test bpf and vm | 16 | # now we just test bpf and vm |
15 | # we will append other kernel selftest in the future | 17 | # we will append other kernel selftest in the future |
@@ -22,7 +24,7 @@ PACKAGECONFIG[vm] = ",,,libgcc bash" | |||
22 | 24 | ||
23 | do_patch[depends] += "virtual/kernel:do_shared_workdir" | 25 | do_patch[depends] += "virtual/kernel:do_shared_workdir" |
24 | 26 | ||
25 | inherit linux-kernel-base kernel-arch | 27 | inherit linux-kernel-base kernel-arch ptest |
26 | 28 | ||
27 | do_populate_lic[depends] += "virtual/kernel:do_patch" | 29 | do_populate_lic[depends] += "virtual/kernel:do_patch" |
28 | 30 | ||
diff --git a/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/run-ptest b/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/run-ptest new file mode 100755 index 000000000..d40b9576d --- /dev/null +++ b/meta-oe/recipes-kernel/kernel-selftest/kernel-selftest/run-ptest | |||
@@ -0,0 +1,11 @@ | |||
1 | #!/bin/sh | ||
2 | export PATH=$PATH:/usr/kernel-selftest/bpf | ||
3 | |||
4 | # test_align | ||
5 | test_align | grep "12 pass" &> /dev/null | ||
6 | if [ $? == 0 ]; then | ||
7 | echo "[PASS]: test_align" | ||
8 | else | ||
9 | echo "[FAIL]: test_align" | ||
10 | fi | ||
11 | |||