Several tests define the same time values. Move them all to
common header to avoid code duplication.
Signed-off-by: Daniel Wagner <dwagner@suse.de>
Signed-off-by: John Kacur <jkacur@redhat.com>
- Update the man page with the -s or --smp option
- Reorder the program help to match the man page
- Make the -h option work correctly
Signed-off-by: John Kacur <jkacur@redhat.com>
Add SPDX tags instead of having out-of-date and incomplete licences at
the top of files
Audited again to make sure that GPL-2.0-only is used where appropriate
and not GPL-2.0-or-later (and the other way around)
Signed-off-by: John Kacur <jkacur@redhat.com>
tracing_enabled was deprecated a long time ago and is no longer
available, use tracing_on instead
To reproduce
This patches fixes that
Signed-off-by: Qiao Zhao <qzhao@redhat.com>
Signed-off-by: John Kacur <jkacur@redhat.com>
gettid is defined in rt-utils, so we should use that everywhere instead
of defining a separate macro in each test for it.
Signed-off-by: John Kacur <jkacur@redhat.com>
Acked-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Acked-by: Kurt Kanzenbach <kurt.kanzenbach@linutronix.de>
Many of the test programs have the --loop argument for automatic
stopping. The main problem with the --loop argument is how long is
--loop 1000?
To simplify automated tests introduce a --duration argument which
allows to set the time how long a test should run. This allows the
test suite to define the execution time and also the timeout which a
normal human can understand.
For example run the test for 10 minutes and timeout at 11 minutes:
# timeout 11m ptsematest -D 10m
Signed-off-by: Daniel Wagner <wagi@monom.org>
Signed-off-by: John Kacur <jkacur@redhat.com>
Fix a number of errors like procesor->processor, specifed->specified and
cylictest->cyclictest.
Note, Uwe Kleine-König <ukleinek@debian.org> pointed out some of these
spelling errors previously.
Signed-off-by: John Kacur <jkacur@redhat.com>
Adding _STRING doesn't add any extra meaning, but the extra length makes
the Makefile more unreadable than is necessary, so shorten this up
Signed-off-by: John Kacur <jkacur@redhat.com>
Discovered while compiling with "hardening flags"
For Debian 7.0 (aka wheezy) packages it's recommended to use several
hardening flags, the default on amd64 being:
CFLAGS=-g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security
CPPFLAGS=-D_FORTIFY_SOURCE=2
LDFLAGS=-Wl,-z,relro
This patch doesn't fix all warnings but at least makes all programs compile
again by not using char *variables as printf format strings.
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: John Kacur <jkacur@redhat.com>
Add SMP testing option (-S, --smp) to ptsematest, same as in
cyclictest.
Signed-off-by: Carsten Emde <C.Emde@osadl.org>
Acked-by: John Kacur <jkacur@redhat.com>
Add a get_cpu() function to the library.
Most platforms will simply use sched_getcpu()
However, if you have a glibc < 2.6 then
64-bits will use vsyscall for getcpu (if available).
32-bits will use getcpu() (if available)
Signed-off-by: John Kacur <jkacur@redhat.com>
- These changes simplify the Makefile. For example, notice that we no
longer need to specify the full path to the source file
- These changes also unify the Makefile, for example, every program
gets VERSION_STRING as an floating point number.
- Due to the above change I had to make a number of changes in the programs
that expected VERSION_STRING as a string.
- By unifying what we CFLAGS, to include -D_GNU_SOURCE, I had to remove
__USE_GNU which is reduncant in a number of files.
Signed-off-by: John Kacur <jkacur@redhat.com>
Somehow the last set of tests added got converted to DOS text
(CRLF line terminators). Change them back
Signed-off-by: Clark Williams <williams@redhat.com>