Skip to content

Commit 431bb85

Browse files
committed
rtems-test-check: Ignore tests which require real ISR based clock tick
BSPs for simulators which do not include a clock tick interrupt source are incapable of running some tests successfully. This is a common characteristic of some BSPs and a fixed set of tests. There is no point in duplicating this list of tests in those BSPs test configuration. Read testsuites/testdata/require-tick-isr.tcfg for details.
1 parent dac5696 commit 431bb85

File tree

3 files changed

+100
-4
lines changed

3 files changed

+100
-4
lines changed

testsuites/automake/test-subdirs.am

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ all-local:
2222
fi; \
2323
echo "BSP Testsuite Data: $$vtdata"; \
2424
list=`$(top_srcdir)/../../tools/build/rtems-test-check \
25-
$$tdata $(RTEMS_BSP) $(_SUBDIRS)`; \
25+
$$tdata $(top_srcdir)/.. $(RTEMS_BSP) $(_SUBDIRS)`; \
2626
for subdir in $$list; do \
2727
echo "Making $$target in $$subdir"; \
2828
if test "$$subdir" != "."; then \
Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
#
2+
# These tests require that the BSP have a real clock tick ISR. Some
3+
# simulator BSPs do not have any interrupt sources and use the file
4+
# libbsp/shared/clock_driver_simidle.c.
5+
#
6+
# Tests which do not work with this clock driver tend to have the
7+
# one of the following characteristics:
8+
#
9+
# + Assume that a clock tick will occur while a task is running
10+
# continuously can be
11+
# + Assume that a timer service routine will execute in an ISR
12+
# while a task is running continously.
13+
# + Has a busy spin loop waiting to start the test on a tick boundary
14+
# does this.
15+
#
16+
# Eventually there should be a way to note that a BSP has a list
17+
# of expected test failures which are specific to it AND a set of
18+
# characteristics that make running classes of test appropriate or
19+
# inappropriate. At that point, this would be one characteristic.
20+
#
21+
# NOTE: Each test in this list should be reviewed to ensure that it
22+
# has a legitimate reason to not run on a BSP with the simulator
23+
# clock idle task. It may need to be broken into multiple tests
24+
# if not executing it misses other paths.
25+
#
26+
cpuuse
27+
psx07
28+
psx09
29+
psx10
30+
psx11
31+
psxcancel01
32+
psxgetrusage01
33+
psxintrcritical01
34+
psxsignal01
35+
psxsignal02
36+
psxspin01
37+
psxtime
38+
psxtimes01
39+
sp04
40+
sp14
41+
sp19
42+
sp35
43+
sp38
44+
sp44
45+
sp69
46+
spcbssched02
47+
spcbssched03
48+
spcontext01
49+
spcpucounter01
50+
spedfsched03
51+
spintrcritical01
52+
spintrcritical02
53+
spintrcritical03
54+
spintrcritical04
55+
spintrcritical05
56+
spintrcritical06
57+
spintrcritical07
58+
spintrcritical08
59+
spintrcritical09
60+
spintrcritical10
61+
spintrcritical11
62+
spintrcritical12
63+
spintrcritical13
64+
spintrcritical14
65+
spintrcritical15
66+
spintrcritical16
67+
spintrcritical17
68+
spintrcritical18
69+
spintrcritical19
70+
spintrcritical20
71+
spnsext01
72+
spqreslib

tools/build/rtems-test-check

Lines changed: 27 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
#
66

77
#
8-
# usage: rtems-test-check <bsp-test-database> <bsp> <tests..>
8+
# usage: rtems-test-check <bsp-test-database> <includes> <bsp> <tests..>
99
#
1010

1111
if test $# -lt 3; then
@@ -15,6 +15,8 @@ fi
1515

1616
testdata="$1"
1717
shift
18+
includepath="$1"
19+
shift
1820
bsp="$1"
1921
shift
2022
tests="$*"
@@ -23,11 +25,33 @@ bsp_tests=${tests}
2325
#
2426
# If there is no testdata all tests are valid.
2527
#
28+
2629
if test -f $testdata; then
2730
disabled_tests=""
28-
for t in $(cat $testdata | sed -e 's/#.*$//' -e '/^$/d');
31+
while [ ! -z $testdata ];
2932
do
30-
disabled_tests="${disabled_tests} ${t}"
33+
for td in $testdata;
34+
do
35+
ntd=""
36+
exec 3<& 0
37+
exec 0<$td
38+
while read line
39+
do
40+
line=$(echo $line | sed -e 's/#.*$//' -e '/^$/d')
41+
if [ ! -z "$line" ]; then
42+
include=$(echo $line | sed -e "s/include:.*/yes/g")
43+
if [ "$include" = "yes" ]; then
44+
inf=$(echo $line | sed -e "s/include://g" -e 's/^[ \t]//;s/[ \t]$//')
45+
if test -f $includepath/$inf; then
46+
ntd="$includepath/$inf $ntd"
47+
fi
48+
else
49+
disabled_tests="${disabled_tests} $line"
50+
fi
51+
fi
52+
done
53+
done
54+
testdata=$ntd
3155
done
3256

3357
bsp_tests=""

0 commit comments

Comments
 (0)