summaryrefslogtreecommitdiffstats
path: root/kernel/rcu/rcuperf.c
diff options
context:
space:
mode:
authorPaul E. McKenney2017-04-26 00:12:56 +0200
committerPaul E. McKenney2017-06-08 17:25:32 +0200
commit820687a7b98a5031207893ff265f97c0a0ad403e (patch)
tree7ca7ed37ea08413a9e36951ccbd50685ea55da20 /kernel/rcu/rcuperf.c
parentsrcu-cbmc: Use /usr/bin/awk instead of /bin/awk (diff)
downloadkernel-qcow2-linux-820687a7b98a5031207893ff265f97c0a0ad403e.tar.gz
kernel-qcow2-linux-820687a7b98a5031207893ff265f97c0a0ad403e.tar.xz
kernel-qcow2-linux-820687a7b98a5031207893ff265f97c0a0ad403e.zip
rcuperf: Add writer_holdoff boot parameter
This commit adds a writer_holdoff boot parameter to rcuperf, which is intended to be used to test Tree SRCU's auto-expediting. This boot parameter is in microseconds, and defaults to zero (that is, disabled). Set it to a bit larger than srcutree.exp_holdoff, keeping the nanosecond/microsecond conversion, to force Tree SRCU to auto-expedite more aggressively. This commit also adds documentation for this parameter, and fixes some alphabetization while in the neighborhood. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Diffstat (limited to 'kernel/rcu/rcuperf.c')
-rw-r--r--kernel/rcu/rcuperf.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/kernel/rcu/rcuperf.c b/kernel/rcu/rcuperf.c
index 49c8ed6bd2fd..d80f11d9f8bd 100644
--- a/kernel/rcu/rcuperf.c
+++ b/kernel/rcu/rcuperf.c
@@ -68,6 +68,7 @@ torture_param(int, nwriters, -1, "Number of RCU updater threads");
torture_param(bool, shutdown, !IS_ENABLED(MODULE),
"Shutdown at end of performance tests.");
torture_param(bool, verbose, true, "Enable verbose debugging printk()s");
+torture_param(int, writer_holdoff, 0, "Holdoff (us) between GPs, zero to disable");
static char *perf_type = "rcu";
module_param(perf_type, charp, 0444);
@@ -447,6 +448,8 @@ rcu_perf_writer(void *arg)
}
do {
+ if (writer_holdoff)
+ udelay(writer_holdoff);
wdp = &wdpp[i];
*wdp = ktime_get_mono_fast_ns();
if (gp_async) {