diff options
author | Paul E. McKenney <paulmck@kernel.org> | 2020-04-02 05:57:52 +0300 |
---|---|---|
committer | Paul E. McKenney <paulmck@kernel.org> | 2020-05-07 20:15:28 +0300 |
commit | 55b2dcf58700041d6f0b037a98619222c825f004 (patch) | |
tree | da9dcfd0c5feda27e39ddedcdb3b8c514ff4936c /kernel/rcu/rcu.h | |
parent | df5916845dd6ee34ce40aaad5e7b61058720419c (diff) | |
download | linux-55b2dcf58700041d6f0b037a98619222c825f004.tar.xz |
rcu: Allow rcutorture to starve grace-period kthread
This commit provides an rcutorture.stall_gp_kthread module parameter
to allow rcutorture to starve the grace-period kthread. This allows
testing the code that detects such starvation.
Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Diffstat (limited to 'kernel/rcu/rcu.h')
-rw-r--r-- | kernel/rcu/rcu.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/kernel/rcu/rcu.h b/kernel/rcu/rcu.h index 00ddc92c5774..cdbc5f98f584 100644 --- a/kernel/rcu/rcu.h +++ b/kernel/rcu/rcu.h @@ -454,6 +454,7 @@ void do_trace_rcu_torture_read(const char *rcutorturename, unsigned long secs, unsigned long c_old, unsigned long c); +void rcu_gp_set_torture_wait(int duration); #else static inline void rcutorture_get_gp_data(enum rcutorture_type test_type, int *flags, unsigned long *gp_seq) @@ -471,6 +472,7 @@ void do_trace_rcu_torture_read(const char *rcutorturename, #define do_trace_rcu_torture_read(rcutorturename, rhp, secs, c_old, c) \ do { } while (0) #endif +static inline void rcu_gp_set_torture_wait(int duration) { } #endif #if IS_ENABLED(CONFIG_RCU_TORTURE_TEST) || IS_MODULE(CONFIG_RCU_TORTURE_TEST) |