summaryrefslogtreecommitdiffstats
path: root/recipes-test/test-nohz-ticks
diff options
context:
space:
mode:
Diffstat (limited to 'recipes-test/test-nohz-ticks')
-rwxr-xr-xrecipes-test/test-nohz-ticks/files/test-nohz-ticks32
-rw-r--r--recipes-test/test-nohz-ticks/test-nohz-ticks.bb21
2 files changed, 53 insertions, 0 deletions
diff --git a/recipes-test/test-nohz-ticks/files/test-nohz-ticks b/recipes-test/test-nohz-ticks/files/test-nohz-ticks
new file mode 100755
index 0000000..f6d7546
--- /dev/null
+++ b/recipes-test/test-nohz-ticks/files/test-nohz-ticks
@@ -0,0 +1,32 @@
1#!/bin/sh
2
3cd /opt/ltp >/dev/null
4
5partitioning_done=false
6
7# Perform partitioning, if not already done
8if [ ! -d /sys/fs/cgroup/cpuset/rt ]; then
9 partrt create 0x$(list2mask --nohz)
10 partitioning_done=true
11fi
12
13logname=`date +"%Y_%m_%d_%H_%M_%S"`".log"
14./runltp -n -i 5 -p -d /tmp -l $logname -f partrt_nohz_full
15
16if [ ! -d ./results ]; then
17 echo "FAIL: no result found"
18 $partitioning_done && partrt undo
19 exit 1
20fi
21
22cat ./results/$logname | while read line
23do
24 resultLine=`echo $line | grep -c -E "PASS|FAIL"`
25 if [ $resultLine -eq 1 ]; then
26 testcase=`echo $line | awk '{print $1}'`
27 result=`echo $line | awk '{print $2}'`
28 echo "$result: $testcase"
29 fi
30done
31
32$partitioning_done && partrt undo
diff --git a/recipes-test/test-nohz-ticks/test-nohz-ticks.bb b/recipes-test/test-nohz-ticks/test-nohz-ticks.bb
new file mode 100644
index 0000000..047cffd
--- /dev/null
+++ b/recipes-test/test-nohz-ticks/test-nohz-ticks.bb
@@ -0,0 +1,21 @@
1
2LICENSE = "BSD"
3LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
4INHIBIT_DEFAULT_DEPS = "1"
5
6SRC_URI = "file://${PN} \
7 "
8
9FILES_${PN} += "${bindir}/${PN}"
10
11RDEPENDS_${PN} = "ltp packagegroup-enea-rt-tools"
12
13do_install () {
14 install -D ${WORKDIR}/${PN} ${D}${bindir}/${PN}
15}
16
17# Only a script, no need for patch, configure, compile or build
18do_patch[noexec] = "1"
19do_configure[noexec] = "1"
20do_compile[noexec] = "1"
21do_build[noexec] = "1"