summaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/rcutorture
AgeCommit message (Collapse)AuthorFilesLines
2020-05-07Merge branches 'fixes.2020.04.27a', 'kfree_rcu.2020.04.27a', ↵Paul E. McKenney13-27/+123
'rcu-tasks.2020.04.27a', 'stall.2020.04.27a' and 'torture.2020.05.07a' into HEAD fixes.2020.04.27a: Miscellaneous fixes. kfree_rcu.2020.04.27a: Changes related to kfree_rcu(). rcu-tasks.2020.04.27a: Addition of new RCU-tasks flavors. stall.2020.04.27a: RCU CPU stall-warning updates. torture.2020.05.07a: Torture-test updates.
2020-05-07torture: Add a --kasan argumentPaul E. McKenney2-0/+6
Make it a bit easier to apply KASAN to rcutorture runs with a new --kasan argument, again leveraging the config_override_param() bash function. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-05-07torture: Save a few lines by using config_override_param initiallyPaul E. McKenney1-22/+16
This commit saves a few lines of code by also using the bash config_override_param() to set the initial list of Kconfig options from the CFcommon file. While in the area, it makes this function capable of update-in-place on the file containing the cumulative Kconfig options, thus avoiding annoying changes when adding another source of options. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-05-07torture: Allow scenario-specific Kconfig options to override CFcommonPaul E. McKenney1-4/+3
This commit applies config_override_param() to allow scenario-specific Kconfig options to override those in CFcommon. This in turn will allow additional Kconfig options to be placed in CFcommon, for example, an option common to all but a few scenario can be placed in CFcommon and then overridden in those few scenarios. Plus this change saves one whole line of code. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-05-07torture: Allow --kconfig options to override --kcsan defaultsPaul E. McKenney2-6/+4
Currently, attempting to override a --kcsan default with a --kconfig option might or might not work. However, it would be good to allow the user to adjust the --kcsan defaults, for example, to specify a different time for CONFIG_KCSAN_REPORT_ONCE_IN_MS. This commit therefore uses the new config_override_param() bash function to apply the --kcsan defaults and then apply the --kconfig options, which allows this overriding to occur. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-05-07torture: Abstract application of additional Kconfig optionsPaul E. McKenney1-11/+20
This commit introduces a config_override_param() bash function that folds in an additional set of Kconfig options. This is initially applied to fold in the --kconfig kvm.sh parameter, but later commits will also apply it to the Kconfig options added by the --kcsan kvm.sh parameter. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-05-07torture: Eliminate duplicate #CHECK# from ConfigFragmentPaul E. McKenney1-4/+2
The #CHECK# directives that can be present in CFcommon and in the rcutorture scenario Kconfig files are both copied to ConfigFragment and grepped out of the two directive files and added to ConfigFragment. This commit therefore removes the redundant "grep" commands and takes advantage of the consequent opportunity to simplify redirection. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-05-07torture: Make --kcsan argument also create a summaryPaul E. McKenney3-0/+32
The KCSAN tool emits a great many warnings for current kernels, for example, a one-hour run of the full set of rcutorture scenarios results in no fewer than 3252 such warnings, many of which are duplicates or are otherwise closely related. This commit therefore introduces a kcsan-collapse.sh script that maps these warnings down to a set of function pairs (22 of them given the 3252 individual warnings), placing the resulting list in decreasing order of frequency of occurrence into a kcsan.sum file. If any KCSAN warnings were produced, the pathname of this file is emitted at the end of the summary of the rcutorture runs. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-05-07torture: Add --kcsan argument to top-level kvm.sh scriptPaul E. McKenney1-0/+8
Although the existing --kconfig argument can be used to run KCSAN for an rcutorture test, it is not as straightforward as one might like: --kconfig "CONFIG_DEBUG_INFO=y CONFIG_KCSAN=y \ CONFIG_KCSAN_ASSUME_PLAIN_WRITES_ATOMIC=n \ CONFIG_KCSAN_REPORT_VALUE_CHANGE_ONLY=n \ CONFIG_KCSAN_REPORT_ONCE_IN_MS=100000 \ CONFIG_KCSAN_VERBOSE=y CONFIG_KCSAN_INTERRUPT_WATCHER=y" This commit therefore adds a "--kcsan" argument that emulates the above --kconfig command. Note that if you specify a Kconfig option using -kconfig that conflicts with one that --kcsan adds, you get whatever the script and the build system decide to give you. Cc: Marco Elver <elver@google.com> Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-05-07rcutorture: Right-size TREE10 CPU consumptionPaul E. McKenney1-1/+1
The number of CPUs is tuned to allow "4*CFLIST TREE10" on a large system, up from "3*CFLIST TREE10" previously. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-04-27rcutorture: Make kvm-recheck-rcu.sh handle truncated linesPaul E. McKenney1-1/+15
System hangs or killed rcutorture guest OSes can result in truncated "Reader Pipe:" lines, which can in turn result in false-positive reader-batch near-miss warnings. This commit therefore adjusts the reader-batch checks to account for possible line truncation. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-04-27rcutorture: Add TRACE02 scenario enabling RCU Tasks Trace IPIsPaul E. McKenney4-0/+14
This commit adds a TRACE02 scenario which enables preemption and RCU Tasks Trace IPIs, more specifically, disabling heavyweight readers. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-04-27rcutorture: Add torture tests for RCU Tasks TracePaul E. McKenney3-0/+12
This commit adds the definitions required to torture the tracing flavor of RCU tasks. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-04-27rcutorture: Add torture tests for RCU Tasks RudePaul E. McKenney3-0/+12
This commit adds the definitions required to torture the rude flavor of RCU tasks. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-04-03Merge tag 'spdx-5.7-rc1' of ↵Linus Torvalds4-0/+4
git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/spdx Pull SPDX updates from Greg KH: "Here are three SPDX patches for 5.7-rc1. One fixes up the SPDX tag for a single driver, while the other two go through the tree and add SPDX tags for all of the .gitignore files as needed. Nothing too complex, but you will get a merge conflict with your current tree, that should be trivial to handle (one file modified by two things, one file deleted.) All three of these have been in linux-next for a while, with no reported issues other than the merge conflict" * tag 'spdx-5.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/spdx: ASoC: MT6660: make spdxcheck.py happy .gitignore: add SPDX License Identifier .gitignore: remove too obvious comments
2020-03-25.gitignore: add SPDX License IdentifierMasahiro Yamada4-0/+4
Add SPDX License Identifier to all .gitignore files. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-03-21Merge branches 'doc.2020.02.27a', 'fixes.2020.03.21a', ↵Paul E. McKenney6-3/+40
'kfree_rcu.2020.02.20a', 'locktorture.2020.02.20a', 'ovld.2020.02.20a', 'rcu-tasks.2020.02.20a', 'srcu.2020.02.20a' and 'torture.2020.02.20a' into HEAD doc.2020.02.27a: Documentation updates. fixes.2020.03.21a: Miscellaneous fixes. kfree_rcu.2020.02.20a: Updates to kfree_rcu(). locktorture.2020.02.20a: Lock torture-test updates. ovld.2020.02.20a: Updates to callback-overload handling. rcu-tasks.2020.02.20a: RCU-tasks updates. srcu.2020.02.20a: SRCU updates. torture.2020.02.20a: Torture-test updates.
2020-02-20rcutorture: Set KCSAN Kconfig options to detect more data racesPaul E. McKenney1-0/+2
This commit enables the KCSAN Kconfig options that (1) detect data races between reads and writes even when the writes do not change the variable's value and (2) detect data races involving plain C-language writes. These changes only affect scripted rcutorture runs and can be overridden using the kvm.sh --kconfig argument. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-02-20rcutorture: Make kvm-find-errors.sh abort on bad directoryPaul E. McKenney1-0/+2
Currently, kvm-find-errors.sh gives a usage prompt when given a bad directory, but then soldiers on, giving a series of confusing error messages. This commit therefore prints an error message and exits when given a bad directory, hopefully reducing confusion. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-02-20rcutorture: Summarize summary of build and run resultsPaul E. McKenney1-1/+16
When running the default list of tests, the run summary of a successful (that is, failed to find any errors) run fits easily on a 24-line screen. But a run with something like "--configs '5*CFLIST'" will be 80 lines long, and it is all too easy to miss a failure message when scrolling back. This commit therefore prints out the number of runs with failing builds or runtime failures, but only if there are any such failures. For example, a run with a single build error and a single runtime error would print two lines like this: 1 runs with build errors. 1 runs with runtime errors. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-02-20rcutorture: Add 100-CPU configurationPaul E. McKenney1-0/+18
The small-system rcutorture configurations have served us well for a great many years, but it is now time to add a larger one. This commit does just that, but does not add it to the defaults in CFLIST. This allows the kvm.sh argument '--configs "4*CFLIST TREE10" to run four instances of each of the default configurations concurrently with one instance of the large configuration. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-02-20torture: Make results-directory date format completion-friendlyPaul E. McKenney1-1/+1
The names of the per-test results directories are of the form 2019.11.29-20:42:19. This works, but the ":" characters make tab-based shell name completion a bit onerous because the user must remember to include a quote character somewhere before the first ":". This commit therefore changes the ":" characters to periods, as in 2019.12.01-20.48.01", which allows tab-based completion to work more naturally. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2020-02-20locktorture: Allow CPU-hotplug to be disabled via --bootargsPaul E. McKenney1-1/+1
The bootparam_hotplug_cpu() bash function was checking for CPU-hotplug kernel-boot parameters from --bootargs, but that check was specific to rcutorture ("rcutorture\.onoff_"). This commit therefore makes this check also work for locktorture ("torture\.onoff_"). Note that rcuperf does not do CPU-hotplug operations, so it is not necessary to make a similar change for rcuperf. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-12-09torture: Hoist calls to lscpu to higher-level kvm.sh scriptPaul E. McKenney2-7/+11
On some kernels, concurrent calls to the lscpu command result in severe slowdowns. For example, on v4.16, a single lscpu invocation takes about two milliseconds, four concurrent invocations more than two seconds, and 16 concurrent invocations more than 20 seconds. Given that the only goal is to learn the number of CPUs, invoking lscpu but once suffices. This commit therefore invokes lscpu early in kvm.sh execution, setting the initial value of the TORTURE_ALLOTED_CPUS environment variable. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-12-09torture: Allow "CFLIST" to specify default list of scenariosPaul E. McKenney1-6/+13
On a large system, it can be convenient to tell rcutorture to run several instances of the default scenarios. Currently, this requires explicitly listing them, for example, "--configs '2*SRCU-N 2*SRCU-P...'". Although this works, it is rather inconvenient. This commit therefore allows "CFLIST" to be specified to indicate the default list of scenarios called out in the relevant CFLIST file, for example, for RCU, tools/testing/selftests/rcutorture/configs/rcu/CFLIST. In addition, multipliers may be used to run multiple instances of all the scenarios. For example, on a 256-CPU system, "--configs '3*CFLIST'" would run three instances of each scenario concurrently with one CPU left over. Thus "--configs '3*CFLIST TINY01'" would exactly consume all 256 CPUs, which makes rcutorture's jitter feature more effective. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-12-09rcutorture: Add worst-case call_rcu() forward-progress resultsPaul E. McKenney1-1/+2
This commit adds the worst-case results from any call_rcu() forward-progress tests to the rcutorture test-summary output. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-12-09torture: Handle systems lacking the mpstat commandPaul E. McKenney1-2/+9
The rcutorture scripting uses the mpstat command to determine how much the system is being used, and adjusts make's -j argument accordingly. However, mpstat isn't installed by default, so it would be good if the scripting does something useful when mpstat isn't present. This commit therefore makes the scripts assumes that if mpstat is not present, they are free to use all the CPUs. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-12-09torture: Handle jitter for CPUs that cannot be offlinedPaul E. McKenney1-6/+20
Currently, jitter.sh assumes that the underlying hypervisor will be configured with all CPUs hotpluggable, with the possible exception of CPU 0. However, there are installations where the hypervisor prohibits offlining, which breaks jitter.sh. This commit therefore lists the CPUs that cannot be offlined up front, and checks for the case where no CPU can be offlined in the loop. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-12-09rcutorture: Dispense with Dracut for initrd creationPaul E. McKenney1-52/+3
The dracut scripting does not work on all platforms, and there are no known failures from the init binary based on the statically linked C program. This commit therefore removes the dracut scripting so that the statically linked C program is always used to create the init "script". Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-12-09torture: Use gawk instead of awk for systime() functionPaul E. McKenney2-5/+5
In many environments, gawk provides systime(), but awk doesn't. This commit therefore changes awk scripts using systime() to instead be gawk scripts. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-10-05rcutorture: Remove CONFIG_HOTPLUG_CPU=n from scenariosPaul E. McKenney8-22/+0
A number of mainstream CPU families are no longer capable of building kernels having CONFIG_SMP=y and CONFIG_HOTPLUG_CPU=n, so this commit removes this combination from the rcutorture scenarios having it. People wishing to try out this combination may still do so using the "--kconfig CONFIG_HOTPLUG_CPU=n CONFIG_SUSPEND=n CONFIG_HIBERNATION=n" argument to the tools/testing/selftests/rcutorture/bin/kvm.sh script that is used to run rcutorture. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
2019-08-01rcutorture: Test TREE03 with the threadirqs kernel boot parameterPaul E. McKenney1-0/+1
Since commit 05f415715ce45 ("rcu: Speed up expedited GPs when interrupting RCU reader") in v5.0 and through v5.1, booting with the threadirqs kernel boot parameter caused self-deadlocks, which can be reproduced using the following command on an 8-CPU system: tools/testing/selftests/rcutorture/bin/kvm.sh --duration 5 --configs "TREE03" --bootargs "threadirqs" This commit therefore adds the threadirqs kernel boot parameter to the TREE03 rcutorture scenario in order to more quickly detect future similar bugs. Link: http://lkml.kernel.org/r/20190626135447.y24mvfuid5fifwjc@linutronix.de Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com> Cc: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Cc: Joel Fernandes <joel@joelfernandes.org>
2019-08-01torture: Expand last_ts variable in kvm-test-1-run.shPaul E. McKenney1-1/+1
The kvm-test-1-run.sh script says 'test -z "last_ts"' which always evaluates to true (AKA zero) regardless of the value of the last_ts shell variable. This commit therefore inserts the needed dollar sign ("$"). Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28torture: Suppress propagating trace_printk() warningPaul E. McKenney1-0/+1
When trace_printk() is used, a message including "BUG" is printed to the console, which fools the rcutorture scripting into believing that the corresponding test scenario failed. This commit therefore filters out this particular instance of "BUG", thus avoiding the false-positive test-failure report. Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28torture: Add --trust-make to suppress "make clean"Paul E. McKenney3-2/+11
The current rcutorture scripts unconditionally do "make clean", which is a good way of getting the needed testing done despite any imperfections in Makefile dependency tracking. However, this can be a bit irritating when repeatedly running a single scenario after small changes, for example, when debugging a problem that affects only a single scenario. This commit therefore adds a --trust-make argument that suppresses the "make clean". Even when using ccache, this speeds up kernel builds by up to almost an order of magnitude on my laptop. Reported-by: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28torture: Make --cpus override idleness calculationsPaul E. McKenney2-0/+8
Currently, rcutorture will use relatively few CPUs to build the kernel on a busy system, which is often as it should be. However, if the user has used the --cpus argument to dedicate a specified number of CPUs to this torture test, it would be good if the kernel build also made use of them. This commit therefore changes the cpus2use.sh script to use --cpus when specified and to do the idleness calculations otherwise. Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28torture: Run kernel build in source directoryPaul E. McKenney4-47/+22
For historical reasons, rcutorture places its build products in a tools/testing/selftests/rcutorture/b1 directory using the O= kbuild command-line argument. However, doing this requires that the source directory be pristine: Not just "make clean" pristine, but instead "make mrproper" (or, equivalently, "make distclean") pristine. Therefore, rcutorture executes a "make mrproper" before each build. Unfortunately, "make mrproper" has the side effect of removing pretty much everything, including tags files and cscope databases, which can be inconvenient to people whose workflow centers around a single source tree. This commit therefore makes rcutorture do the build directly in the source directory, removing the need for "make mrproper". This works because all needed build products are moved to their proper place in the "res" directory immediately after the build completes, so that multiple rcutorture kernels can still run concurrently. Reported-by: Peter Zijlstra <peterz@infradead.org> Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28torture: Add function graph-tracing cheat sheetPaul E. McKenney1-0/+2
Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28torture: Capture qemu outputPaul E. McKenney2-2/+10
Currently qemu output appears on standard output, but is inaccessible later on. This commit therefore captures this output and causes kvm-recheck.sh to output this output if QEMU gave a non-zero non-137 exit code. (And exit code of 137 indicates that QEMU was killed, in which case we want to know about the hang rather than the fact that QEMU was killed.) Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28rcutorture: Tweak kvm optionsSebastian Andrzej Siewior2-1/+15
In one of my rcutorture tests the TSC clocksource got marked unstable due to a large difference in the TSC value. I'm not sure if the guest run for a long time with disabled interrupts or if the host was very busy and didn't schedule the guest for some time. I took a look on the qemu/KVM options and decided to update the options: - Use kvm{32|64} as CPU. We could probably use `host' (like ARM does) for maximum available features but since we don't run any userland I'm not sure if it makes any difference. - Drop the "noapic" option. There is no history why the APIC was disabled, I see no reason for it. Once old qemu versions fade away, we can add "x2apic=on,tsc-deadline=on,hypervisor=on,tsc_adjust=on". - Additional config options. It ensures that the kernel knowns that it runs as a kvm guest and can use virt devices like the kvm-clock as clocksource. The kvm-clock was the main motivation here. - I didn't add a random HW device. It would make the random device ready earlier (not it doesn't complete the initialisation at all) but I doubt that there is any need for this. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> [ paulmck: The world is not quite ready for CONFIG_PARAVIRT_SPINLOCKS=y and x2apic, so they are omitted for the time being. ] Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28rcutorture: Add trivial RCU implementationPaul E. McKenney2-0/+17
I have been showing off a trivial RCU implementation for non-preemptive environments for some time now: #define rcu_read_lock() #define rcu_read_unlock() #define rcu_dereference(p) READ_ONCE(p) #define rcu_assign_pointer(p, v) smp_store_release(&(p), (v)) void synchronize_rcu(void) { int cpu; for_each_online_cpu(cpu) sched_setaffinity(current->pid, cpumask_of(cpu)); } Trivial or not, as the old saying goes, "if it ain't tested, it don't work!". This commit therefore adds a "trivial" flavor to rcutorture and a corresponding TRIVIAL test scenario. This variant does not handle CPU hotplug, which is unconditionally enabled on x86 for post-v5.1-rc3 kernels, which is why the TRIVIAL.boot says "rcutorture.onoff_interval=0". This commit actually does handle CONFIG_PREEMPT=y kernels, but only because it turns back the Linux-kernel clock in order to provide these alternative definitions (or the moral equivalent thereof): #define rcu_read_lock() preempt_disable() #define rcu_read_unlock() preempt_enable() In CONFIG_PREEMPT=n kernels without debugging, these are equivalent to empty macros give or take a compiler barrier. However, the have been successfully tested with actual empty macros as well. Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com> [ paulmck: Fix symbol issue reported by kbuild test robot <lkp@intel.com>. ] [ paulmck: Work around sched_setaffinity() issue noted by Andrea Parri. ] [ paulmck: Add rcutorture.shuffle_interval=0 to TRIVIAL.boot to fix interaction with shuffler task noted by Peter Zijlstra. ] Tested-by: Andrea Parri <andrea.parri@amarulasolutions.com>
2019-05-28rcutorture: Exempt TREE01 from forward-progress testingPaul E. McKenney1-0/+1
Because TREE01 can end up running more vCPUs that physical CPUs, hammering these shortchanged CPUs with tight loops containing call_rcu() invocations seems a bit like overkill. This commit therefore exempts TREE01 from rcutorture's forward-progress testing. Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28rcutorture: Provide rudimentary MakefilePaul E. McKenney1-0/+3
This commit provides a rudimentary Makefile that runs a 10-minute rcutorture test on scenario TREE01. This must be run on a system capable of spawning virtual machines and with everything installed to permit building Linux kernels. Reported-by: Shuah Khan <shuah@kernel.org> Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28torture: Make kvm-find-errors.sh and kvm-recheck.sh provide exit statusPaul E. McKenney2-0/+6
This commit causes both kvm-find-errors.sh and kvm-recheck.sh to provide an exit status based on whether or not errors were located. In the case of kvm-recheck.sh, this will be the error status of the last run. This change allows these commands to be used in scripting and Makefiles to automatically report failed rcutorture runs. Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28rcutorture: Add cpu0 to the set of CPUs to add jitterJoel Fernandes (Google)1-2/+6
jitter.sh currently does not add CPU0 to the list of CPUs for adding of jitter. Let us add it to this list even when it is not hot-pluggable. Signed-off-by: Joel Fernandes (Google) <joel@joelfernandes.org> Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-28rcutorture: Select from only online CPUsJoel Fernandes (Google)1-2/+3
The rcutorture jitter.sh script selects a random CPU but does not check if it is offline or online. This leads to taskset errors many times. On my machine, hyper threading is disabled so half the cores are offline causing taskset errors a lot of times. Let us fix this by checking from only the online CPUs on the system. Cc: rcu@vger.kernel.org Signed-off-by: Joel Fernandes (Google) <joel@joelfernandes.org> Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-05-07Merge tag 'for-5.2/block-20190507' of git://git.kernel.dk/linux-blockLinus Torvalds1-4/+0
Pull block updates from Jens Axboe: "Nothing major in this series, just fixes and improvements all over the map. This contains: - Series of fixes for sed-opal (David, Jonas) - Fixes and performance tweaks for BFQ (via Paolo) - Set of fixes for bcache (via Coly) - Set of fixes for md (via Song) - Enabling multi-page for passthrough requests (Ming) - Queue release fix series (Ming) - Device notification improvements (Martin) - Propagate underlying device rotational status in loop (Holger) - Removal of mtip32xx trim support, which has been disabled for years (Christoph) - Improvement and cleanup of nvme command handling (Christoph) - Add block SPDX tags (Christoph) - Cleanup/hardening of bio/bvec iteration (Christoph) - A few NVMe pull requests (Christoph) - Removal of CONFIG_LBDAF (Christoph) - Various little fixes here and there" * tag 'for-5.2/block-20190507' of git://git.kernel.dk/linux-block: (164 commits) block: fix mismerge in bvec_advance block: don't drain in-progress dispatch in blk_cleanup_queue() blk-mq: move cancel of hctx->run_work into blk_mq_hw_sysfs_release blk-mq: always free hctx after request queue is freed blk-mq: split blk_mq_alloc_and_init_hctx into two parts blk-mq: free hw queue's resource in hctx's release handler blk-mq: move cancel of requeue_work into blk_mq_release blk-mq: grab .q_usage_counter when queuing request from plug code path block: fix function name in comment nvmet: protect discovery change log event list iteration nvme: mark nvme_core_init and nvme_core_exit static nvme: move command size checks to the core nvme-fabrics: check more command sizes nvme-pci: check more command sizes nvme-pci: remove an unneeded variable initialization nvme-pci: unquiesce admin queue on shutdown nvme-pci: shutdown on timeout during deletion nvme-pci: fix psdt field for single segment sgls nvme-multipath: don't print ANA group state by default nvme-multipath: split bios with the ns_head bio_set before submitting ...
2019-04-06block: remove CONFIG_LBDAFChristoph Hellwig1-4/+0
Currently support for 64-bit sector_t and blkcnt_t is optional on 32-bit architectures. These types are required to support block device and/or file sizes larger than 2 TiB, and have generally defaulted to on for a long time. Enabling the option only increases the i386 tinyconfig size by 145 bytes, and many data structures already always use 64-bit values for their in-core and on-disk data structures anyway, so there should not be a large change in dynamic memory usage either. Dropping this option removes a somewhat weird non-default config that has cause various bugs or compiler warnings when actually used. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
2019-03-26torture: Suppress false-positive CONFIG_INITRAMFS_SOURCE complaintPaul E. McKenney1-0/+1
The scripting must supply the CONFIG_INITRAMFS_SOURCE Kconfig option so that kbuild can find the desired initrd, but the configcheck.sh script gets confused by this option because it takes a string instead of the expected y/n/m. This causes checkconfig.sh to complain about CONFIG_INITRAMFS_SOURCE in the torture-test output (though not in the summary). As more people use rcutorture, the resulting confusion is an increasing concern. This commit therefore suppresses this false-positive warning by filtering CONFIG_INITRAMFS_SOURCE from within the checkconfig.sh script. Reported-by: Joel Fernandes <joel@joelfernandes.org> Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
2019-03-26tools/.../rcutorture: Convert to SPDX license identifierPaul E. McKenney22-314/+47
Replace the license boiler plate with a SPDX license identifier. While in the area, update an email address and add copyright notices. Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>