aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing (follow)
AgeCommit message (Collapse)AuthorFilesLines
2015-03-19selftests: Set CC using CROSS_COMPILE once in lib.mkMichael Ellerman8-9/+5
This avoids repeating the logic in every Makefile. We mimic the top-level Makefile and use $(CROSS_COMPILE)gcc. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-19selftests: Add install support for the powerpc testsMichael Ellerman8-82/+73
The bulk of the selftests are actually below the powerpc sub directory. This adds support for installing them, when on a powerpc machine, or if ARCH and CROSS_COMPILE are set appropriately. This is a little more complicated because of the sub directory structure under powerpc, but much of the common logic in lib.mk is still used. The net effect of the patch is still a reduction in code. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-19selftests/timers: Use shared logic to run and install testsMichael Ellerman2-16/+13
Change the timers Makefile to make use of shared run and install logic in lib.mk. Destructive tests are installed but not run by default. Add a new variable, TEST_PROGS_EXTENDED, which is a list of extra programs to install, but which are not run by the default run_tests logic. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-19kselftest/timers: Set default threadtest values to simplify execution scriptsJohn Stultz1-2/+6
In order to keep the kselftest Makefiles simpler, set the threadtest default values to the ones used in standard run_tests Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-13selftests: Add install targetMichael Ellerman10-1/+73
This adds make install support to selftests. The basic usage is: $ cd tools/testing/selftests $ make install That installs into tools/testing/selftests/install, which can then be copied where ever necessary. The install destination is also configurable using eg: $ INSTALL_PATH=/mnt/selftests make install The implementation uses two targets in the child makefiles. The first "install" is expected to install all files into $(INSTALL_PATH). The second, "emit_tests", is expected to emit the test instructions (ie. bash script) on stdout. Separating this from install means the child makefiles need no knowledge of the location of the test script. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-13selftests: Introduce minimal shared logic for running testsMichael Ellerman29-67/+65
This adds a Make include file which most selftests can then include to get the run_tests logic. On its own this has the advantage of some reduction in repetition, and also means the pass/fail message is defined in fewer places. However the key advantage is it will allow us to implement install very simply in a subsequent patch. The default implementation just executes each program in $(TEST_PROGS). We use a variable to hold the default implementation of $(RUN_TESTS) because that gives us a clean way to override it if necessary, ie. using override. The mount, memory-hotplug and mqueue tests use that to provide a different implementation. Tests are not run via /bin/bash, so if they are scripts they must be executable, we add a+x to several. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add set-2038 test from timetest suiteJohn Stultz2-1/+146
Adds the set-2038 test which sets the time to near-edge cases like the start and end of the 32 bit epoch and checks that time behaves properly. There is also a dangerous mode, which lets the clock roll over past 2038 on 32bit systems, which on some older kernels will cause system hangs. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add set-tai from the timetest suiteJohn Stultz2-1/+81
This patch adds the set-tai test which ensures the tai offset can be set properly from adjtimex. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add leapcrash test from the timetest suiteJohn Stultz2-1/+122
This change adds the leapcrash test which tests to see if a leapsecond deadlock which was observed from 2.6.26 to 3.3 is present on this system. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add leap-a-day test from timetest suiteJohn Stultz2-0/+321
This change adds the leap-a-day test which sets STA_INS and STA_DEL each day to trigger leapseconds each day. It also has a mode to jump the time to right before the end of the day each iteration. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add clocksource-switch test from timetest suiteJohn Stultz2-1/+181
Adds the clocksource-switch tests which continually switches the current clocksource between all the available ones, watching for any timekeeping inconsistencies. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add skew_consistency test from the timetests suiteJohn Stultz2-1/+91
This change adds the skew_consistency test, which twists the ADJ_FREQUENCY knob back and forth and watches for timekeeping inconsistencies. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add change_skew test from timetest suiteJohn Stultz2-1/+109
This patch adds the change_skew test which validates the adjtimex freq can be set to various values and then using the inconsistency-check, raw_skew, and nanosleep tests ensures time behaves properly. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add alarmtimer-suspend test from timetests suiteJohn Stultz2-2/+189
This adds the alarmtimer-suspend test from the timetests suite, which tests that the alarmtimers wake the system up from suspend shortly after the time they were set to fire. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add adjtimex validation test from timetest suiteJohn Stultz2-1/+212
This adds a adjtimex validation test which checks the behavior for a set of valida and invalid inputs. So far this only tests ADJ_FREQUENCY, but hopefully will grow. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add mqueue latency test from the timetest suiteJohn Stultz2-1/+126
Add test to validate mqueue timeout latency from the timetest suite Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add threaded time inconsistency test from timetest suiteJohn Stultz2-2/+202
Add the threaded time inconsistency test from the timetest suite. This checks for time inconsistencies between cpus, usually associated with clock skew as sometimes found w/ TSCs. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add set-timer-lat test from timetest suiteJohn Stultz2-1/+213
Add my set-timer-lat test from the timetest suite. This test checks the latency from set_timer and reports if any are unreasonable (>40ms). Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add clock skew estimation test from timetest suiteJohn Stultz2-1/+156
This adds my clock skew estimation test from the timetest suite. It measures the drift between CLOCK_MONOTONIC and CLOCK_MONOTONIC_RAW and compares it with the current frequency value from adjtimex. It sometimes can trigger false failures when ntpd isn't in a steady state, but its a useful too when doing adjtimex testing. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add nsleep-lat test from timetest suiteJohn Stultz2-1/+192
Adds my nanosleep latency test from the timetest suite. This checks to make sure we don't see "unreasonable" latencies (> 40ms) when calling nanosleep. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add inconsistency-check test from timetestsJohn Stultz2-2/+206
This adds my inconsistency-test from my timetests suite, which checks for (single threaded) time inconsistencies across the various clockids. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Add nanosleep test from timetest suiteJohn Stultz2-1/+176
Add my basic nanosleep test from my timetest suite. This test validates that nanosleep doesn't return early against a number of clockids. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Quiet warning due to lack of return check on brkJohn Stultz1-5/+4
The posix_timers.c test has a loop that tries to keep it in kernel space, repeatedly calling brk(). However, it doesn't check the return value, which causes warnings. This patch adds a err value which captures the return value and modifies the test so it will quit if a failure occurs. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-03-12selftests/timers: Cleanup Makefile to make it easier to add future testsJohn Stultz1-3/+8
Try to streamline the makefile so its easier to add timer/timekeeping tests. Also adds support for the CROSS_COMPILE variable. Cc: Shuah Khan <shuahkh@osg.samsung.com> Cc: Prarit Bhargava <prarit@redhat.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Richard Cochran <richardcochran@gmail.com> Signed-off-by: John Stultz <john.stultz@linaro.org> Tested-by: Prarit Bhargava <prarit@redhat.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-02-12Merge tag 'ktest-v3.20' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktestLinus Torvalds1-30/+229
Pull ktest updates from Steven Rostedt: "The following ktest updates were done: o Added timings to various parts of the test (build, install, boot, tests) and report them so that the users can keep track of changes. o Josh Poimboeuf fixed the console output to work better with virtual machine targets. o Various clean ups and fixes" * tag 'ktest-v3.20' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktest: ktest: Place quotes around item variable ktest: Cleanup terminal on dodie() failure ktest: Print build,install,boot,test times at success and failure ktest: Enable user input to the console ktest: Give console process a dedicated tty ktest: Rename start_monitor_and_boot to start_monitor_and_install ktest: Show times for build, install, boot and test ktest: Restore tty settings after closing console ktest: Add timings for commands
2015-02-11Merge tag 'powerpc-3.20-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mpe/linuxLinus Torvalds14-4/+393
Pull powerpc updates from Michael Ellerman: - Update of all defconfigs - Addition of a bunch of config options to modernise our defconfigs - Some PS3 updates from Geoff - Optimised memcmp for 64 bit from Anton - Fix for kprobes that allows 'perf probe' to work from Naveen - Several cxl updates from Ian & Ryan - Expanded support for the '24x7' PMU from Cody & Sukadev - Freescale updates from Scott: "Highlights include 8xx optimizations, some more work on datapath device tree content, e300 machine check support, t1040 corenet error reporting, and various cleanups and fixes" * tag 'powerpc-3.20-1' of git://git.kernel.org/pub/scm/linux/kernel/git/mpe/linux: (102 commits) cxl: Add missing return statement after handling AFU errror cxl: Fail AFU initialisation if an invalid configuration record is found cxl: Export optional AFU configuration record in sysfs powerpc/mm: Warn on flushing tlb page in kernel context powerpc/powernv: Add OPAL soft-poweroff routine powerpc/perf/hv-24x7: Document sysfs event description entries powerpc/perf/hv-gpci: add the remaining gpci requests powerpc/perf/{hv-gpci, hv-common}: generate requests with counters annotated powerpc/perf/hv-24x7: parse catalog and populate sysfs with events perf: define EVENT_DEFINE_RANGE_FORMAT_LITE helper perf: add PMU_EVENT_ATTR_STRING() helper perf: provide sysfs_show for struct perf_pmu_events_attr powerpc/kernel: Avoid initializing device-tree pointer twice powerpc: Remove old compile time disabled syscall tracing code powerpc/kernel: Make syscall_exit a local label cxl: Fix device_node reference counting powerpc/mm: bail out early when flushing TLB page powerpc: defconfigs: add MTD_SPI_NOR (new dependency for M25P80) perf/powerpc: reset event hw state when adding it to the PMU powerpc/qe: Use strlcpy() ...
2015-02-03ktest: Place quotes around item variableSteven Rostedt (Red Hat)1-1/+1
Seems that some of the new console logic causes doprint to possibly get evaluated. When printing a commit message that contains parenthesis, it fails with a shell parsing error. This gets fixed when we add quotes around the $item variable, and prevent it from being evaluated by any shell commands. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-02-02ktest: Cleanup terminal on dodie() failureJosh Poimboeuf1-1/+6
If dodie() is called with the console open, restore the terminal's original settings before dying. Link: http://lkml.kernel.org/r/20150130025453.GB20952@treble.redhat.com Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-02-02ktest: Print build,install,boot,test times at success and failureSteven Rostedt (Red Hat)1-0/+4
Since both success and failure may shortcut and exit ktest, it is better to print the status times there too. Once times are printed, the values for the times are reset, so they will not print more than once. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-02-02ktest: Enable user input to the consoleJosh Poimboeuf1-15/+36
Allow the user to send input to the console by putting the terminal in cbreak mode (to allow reading stdin one character at a time) and copying all stdin data to the console's pty. Link: http://lkml.kernel.org/r/bb1bbe7d202c95a3ce7894cfffdd8c725875978e.1422473610.git.jpoimboe@redhat.com Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-02-02ktest: Give console process a dedicated ttyJosh Poimboeuf1-9/+57
Create a pseudoterminal (pty pair) to give the console a dedicated tty so it doesn't mess with ktest's terminal settings. Link: http://lkml.kernel.org/r/37b0127f9efad09ff4fc994334db998141e4f6ca.1422473610.git.jpoimboe@redhat.com Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-01-29ktest: Rename start_monitor_and_boot to start_monitor_and_installSteven Rostedt (Red Hat)1-5/+5
The function start_monitor_and_boot is a misnomer. It use to, but now it starts the monitor and installs. It does not boot. Rename it before I get confused by it again. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-01-29ktest: Show times for build, install, boot and testSteven Rostedt (Red Hat)1-4/+105
Seeing the times for how long a build, install, reboot and the test takes is helpful for analyzing the test process. Seeing how different changes affect the timings. Show the build, install, boot and test times when at the end of the test, or between each interval for tests that do those mulitple times (like bisect and patchcheck). Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-01-27ktest: Restore tty settings after closing consoleJosh Poimboeuf1-0/+7
When ktest runs the console program as a child process, the parent and child share the same tty for stdin and stderr. This is problematic when using a libvirt target. The "virsh console" program makes a lot of changes to the tty settings, making ktest's output hard to read (carriage returns don't work). After ktest exits, the terminal is unusable (CRs broken, stdin isn't echoed). I think the best way to fix this issue would be to create a pseudoterminal (pty pair) so the child process would have a dedicated tty, and then use pipes to connect the two ttys. I'm not sure if that's overkill, but it's far beyond my current Perl abilities. This patch is a much easier way to (partially) fix this issue. It saves the tty settings before opening the console and restores them after closing it. There are still a few places where ktest prints mangled output while the console is open, but the output is much more legible overall, and the terminal works just fine after ktest exits. Link: http://lkml.kernel.org/r/1bb89abc0025cf1d6da657c7ba58bbeb4381a515.1422382008.git.jpoimboe@redhat.com Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-01-27ktest: Add timings for commandsSteven Rostedt (Red Hat)1-0/+13
I find that I usually like to see how long a make or other command takes, and adding a start and end time and reporting how long each command runs (in seconds) is helpful. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2015-01-23selftests/powerpc: Add memcmp testcaseAnton Blanchard6-1/+133
Add a testcase for the new ppc64 memcmp. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2015-01-23selftests/powerpc: Add subpage protection self test.Paul Mackerras3-3/+228
Signed-off-by: Paul Mackerras <paulus@samba.org> Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com> mpe: Fix compile errors and formatting. Add tempfile logic to Makefile. Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2015-01-23selftests/powerpc: Make git ignore all binaries in powerpc test suiteAnshuman Khandual6-0/+32
This patch includes all of the powerpc test binaries into the .gitignore file listing in their respective directories. This will make sure that git ignores all of these test binaries when displaying status. Signed-off-by: Anshuman Khandual <khandual@linux.vnet.ibm.com> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2015-01-21Merge branch 'for-mingo' of git://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu into core/rcuIngo Molnar5-13/+38
Pull RCU updates from Paul E. McKenney: - Documentation updates. - Miscellaneous fixes. - Preemptible-RCU fixes, including fixing an old bug in the interaction of RCU priority boosting and CPU hotplug. - SRCU updates. - RCU CPU stall-warning updates. - RCU torture-test updates. Signed-off-by: Ingo Molnar <mingo@kernel.org>
2015-01-15Merge branches 'doc.2015.01.07a', 'fixes.2015.01.15a', 'preempt.2015.01.06a', 'srcu.2015.01.06a', 'stall.2015.01.16a' and 'torture.2015.01.11a' into HEADPaul E. McKenney5-13/+38
doc.2015.01.07a: Documentation updates. fixes.2015.01.15a: Miscellaneous fixes. preempt.2015.01.06a: Changes to handling of lists of preempted tasks. srcu.2015.01.06a: SRCU updates. stall.2015.01.16a: RCU CPU stall-warning updates and fixes. torture.2015.01.11a: RCU torture-test updates and fixes.
2015-01-10torture: Flag console.log file to prevent holdovers from earlier runsPaul E. McKenney1-0/+1
A system misconfiguration that prevents qemu from running at all (for example, a missing dynamically linked library) will keep the console.log file from the previous run. This can fool the developer into thinking that this failed run actually completed correctly. This commit therefore overwrites the console.log file just before launching qemu. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
2015-01-10torture: Add "-enable-kvm -soundhw pcspk" to qemu command linePaul E. McKenney1-4/+4
More recent qemu implementations really want "-enable-kvm", and the "-soundhw pcspk" makes the script a bit less dependent on odd audio libraries being installed. This commit therefore adds both to the default qemu command line. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
2015-01-10rcutorture: Handle different mpstat versionsPaul E. McKenney1-1/+1
The mpstat command recently added the %gnice column, which messes up the cpu2use.sh script's idle-CPU calculations. This commit therefore uses $NF instead of $12 to select the last (%idle) column. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
2015-01-10rcutorture: Make build-output parsing correctly flag RCU's warningsPaul E. McKenney1-7/+13
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
2015-01-10rcutorture: Issue warnings on close calls due to Reader Batch blowsPaul E. McKenney1-0/+18
Normal rcutorture checking overestimates grace periods somewhat due to the fact that there is a delay from a grace-period request until the start of the corresponding grace period and another delay from the end of that grace period to notification of the requestor. This means that rcutorture's detection of RCU bugs is less sensitive than it might be. It turns out that rcutorture also checks the underlying grace-period "completed" counter (displayed in Reader Batch output), which in theory allows rcutorture to do exact checks. In practice, memory misordering (by both compiler and CPU) can result in false positives. However, experience on x86 shows that these false positives are quite rare, occurring less than one time per 1,000 hours of testing. This commit therefore does the exact checking, giving a warning if any Reader Batch blows happen, and flagging an error if they happen more often than once every three hours in long tests. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
2015-01-08selftests/vm: fix link error for transhuge-stress testAndrey Skvortsov1-1/+1
add -lrt to fix undefined reference to `clock_gettime' error seen when the test is compiled using gcc 4.6.4. Signed-off-by: Andrey Skvortsov <andrej.skvortzov@gmail.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-01-06tools: testing: selftests: mq_perf_tests: Fix infinite loop on ARMdann frazier1-2/+1
We can't use a char type to check for a negative return value since char isn't guaranteed to be signed. Indeed, the char type tends to be unsigned on ARM. Signed-off-by: dann frazier <dann.frazier@canonical.com> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-01-06selftests/exec: allow shell return code of 126David Drysdale1-6/+13
When the shell fails to invoke a script because its path name is too long (ENAMETOOLONG), most shells return 127 to indicate command not found. However, some systems report 126 (which POSIX suggests should indicate a non-executable file) for this case, so allow that too. Reported-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: David Drysdale <drysdale@google.com> Tested-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>
2015-01-06rcutorture: Add checks for stall ending before dump startPaul E. McKenney1-1/+1
The current rcutorture scripting checks for actual stalls (via the "Call Trace:" check), but fails to spot the case where a stall ends just as it is being detected. This commit therefore adds a check for this case. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
2014-12-22selftests/exec: Use %zu to format size_tGeert Uytterhoeven1-2/+2
On 32-bit: execveat.c: In function 'check_execveat_pathmax': execveat.c:183: warning: format '%lu' expects type 'long unsigned int', but argument 3 has type 'size_t' execveat.c:187: warning: format '%lu' expects type 'long unsigned int', but argument 2 has type 'size_t' Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: Shuah Khan <shuahkh@osg.samsung.com>