diff options
author | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 13:53:30 +0200 |
---|---|---|
committer | Adrian Dudau <adrian.dudau@enea.com> | 2014-06-26 13:53:30 +0200 |
commit | c2da06c175b7ce286c2acdf44d891bfdf8cd8def (patch) | |
tree | c8a087a3fc67757076dad105f45ed86d618e2ae6 /recipes-test | |
download | meta-nohz-daisy.tar.gz |
initial commit for Enea Linux 4.0HEADdaisy-eneadaisy
Migrated from the internal git server on the daisy-enea branch
Signed-off-by: Adrian Dudau <adrian.dudau@enea.com>
Diffstat (limited to 'recipes-test')
4 files changed, 111 insertions, 0 deletions
diff --git a/recipes-test/test-nohz-stability/files/test-nohz-stability b/recipes-test/test-nohz-stability/files/test-nohz-stability new file mode 100755 index 0000000..b65fd96 --- /dev/null +++ b/recipes-test/test-nohz-stability/files/test-nohz-stability | |||
@@ -0,0 +1,37 @@ | |||
1 | #!/bin/sh | ||
2 | |||
3 | partitioning_done=false | ||
4 | |||
5 | cleanup () { | ||
6 | $partitioning_done && partrt undo | ||
7 | exit $1 | ||
8 | } | ||
9 | |||
10 | cd /opt/ltp || cleanup 1 | ||
11 | |||
12 | # Perform partitioning, if not already done | ||
13 | if [ ! -d /sys/fs/cgroup/cpuset/rt ]; then | ||
14 | partrt create $(list2mask --nohz) || cleanup 1 | ||
15 | partitioning_done=true | ||
16 | fi | ||
17 | |||
18 | echo | ||
19 | echo "*******" | ||
20 | echo "* NRT *" | ||
21 | echo "*******" | ||
22 | echo | ||
23 | |||
24 | partrt run rt stress -i 1 || cleanup 1 & | ||
25 | CHILD_PID=$! | ||
26 | partrt run nrt systest-runner || cleanup 1 | ||
27 | kill $CHILD_PID || cleanup 1 | ||
28 | |||
29 | echo | ||
30 | echo "******" | ||
31 | echo "* RT *" | ||
32 | echo "******" | ||
33 | echo | ||
34 | |||
35 | partrt run rt systest-runner || cleanup 1 | ||
36 | |||
37 | cleanup 0 | ||
diff --git a/recipes-test/test-nohz-stability/test-nohz-stability.bb b/recipes-test/test-nohz-stability/test-nohz-stability.bb new file mode 100644 index 0000000..5c2405a --- /dev/null +++ b/recipes-test/test-nohz-stability/test-nohz-stability.bb | |||
@@ -0,0 +1,21 @@ | |||
1 | |||
2 | LICENSE = "BSD" | ||
3 | LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58" | ||
4 | INHIBIT_DEFAULT_DEPS = "1" | ||
5 | |||
6 | SRC_URI = "file://${PN} \ | ||
7 | " | ||
8 | |||
9 | FILES_${PN} += "${bindir}/${PN}" | ||
10 | |||
11 | RDEPENDS_${PN} = "ltp packagegroup-enea-rt-tools systest-runner" | ||
12 | |||
13 | do_install () { | ||
14 | install -D ${WORKDIR}/${PN} ${D}${bindir}/${PN} | ||
15 | } | ||
16 | |||
17 | # Only a script, no need for patch, configure, compile or build | ||
18 | do_patch[noexec] = "1" | ||
19 | do_configure[noexec] = "1" | ||
20 | do_compile[noexec] = "1" | ||
21 | do_build[noexec] = "1" | ||
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 | |||
3 | cd /opt/ltp >/dev/null | ||
4 | |||
5 | partitioning_done=false | ||
6 | |||
7 | # Perform partitioning, if not already done | ||
8 | if [ ! -d /sys/fs/cgroup/cpuset/rt ]; then | ||
9 | partrt create 0x$(list2mask --nohz) | ||
10 | partitioning_done=true | ||
11 | fi | ||
12 | |||
13 | logname=`date +"%Y_%m_%d_%H_%M_%S"`".log" | ||
14 | ./runltp -n -i 5 -p -d /tmp -l $logname -f partrt_nohz_full | ||
15 | |||
16 | if [ ! -d ./results ]; then | ||
17 | echo "FAIL: no result found" | ||
18 | $partitioning_done && partrt undo | ||
19 | exit 1 | ||
20 | fi | ||
21 | |||
22 | cat ./results/$logname | while read line | ||
23 | do | ||
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 | ||
30 | done | ||
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 | |||
2 | LICENSE = "BSD" | ||
3 | LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58" | ||
4 | INHIBIT_DEFAULT_DEPS = "1" | ||
5 | |||
6 | SRC_URI = "file://${PN} \ | ||
7 | " | ||
8 | |||
9 | FILES_${PN} += "${bindir}/${PN}" | ||
10 | |||
11 | RDEPENDS_${PN} = "ltp packagegroup-enea-rt-tools" | ||
12 | |||
13 | do_install () { | ||
14 | install -D ${WORKDIR}/${PN} ${D}${bindir}/${PN} | ||
15 | } | ||
16 | |||
17 | # Only a script, no need for patch, configure, compile or build | ||
18 | do_patch[noexec] = "1" | ||
19 | do_configure[noexec] = "1" | ||
20 | do_compile[noexec] = "1" | ||
21 | do_build[noexec] = "1" | ||