diff options
author | Paul E. McKenney <paulmck@linux.ibm.com> | 2019-06-25 16:32:51 -0400 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.ibm.com> | 2019-08-13 17:38:24 -0400 |
commit | f7a81b12d6af42a9d09be1e5f041169f04b0b67a (patch) | |
tree | 6bac3cfa8d0b88bd7b8091a88c20fc09694774ed /kernel/rcu/tree.h | |
parent | 6aacd88d1721e12b013ae4ccf4f17609bd5091f3 (diff) |
rcu/nocb: Print no-CBs diagnostics when rcutorture writer unduly delayed
This commit causes locking, sleeping, and callback state to be printed
for no-CBs CPUs when the rcutorture writer is delayed sufficiently for
rcutorture to complain.
Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
Diffstat (limited to 'kernel/rcu/tree.h')
-rw-r--r-- | kernel/rcu/tree.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/kernel/rcu/tree.h b/kernel/rcu/tree.h index e4df86db8137..c612f306fe89 100644 --- a/kernel/rcu/tree.h +++ b/kernel/rcu/tree.h | |||
@@ -212,7 +212,11 @@ struct rcu_data { | |||
212 | /* The following fields are used by GP kthread, hence own cacheline. */ | 212 | /* The following fields are used by GP kthread, hence own cacheline. */ |
213 | raw_spinlock_t nocb_gp_lock ____cacheline_internodealigned_in_smp; | 213 | raw_spinlock_t nocb_gp_lock ____cacheline_internodealigned_in_smp; |
214 | struct timer_list nocb_bypass_timer; /* Force nocb_bypass flush. */ | 214 | struct timer_list nocb_bypass_timer; /* Force nocb_bypass flush. */ |
215 | bool nocb_gp_sleep; /* Is the nocb GP thread asleep? */ | 215 | u8 nocb_gp_sleep; /* Is the nocb GP thread asleep? */ |
216 | u8 nocb_gp_bypass; /* Found a bypass on last scan? */ | ||
217 | u8 nocb_gp_gp; /* GP to wait for on last scan? */ | ||
218 | unsigned long nocb_gp_seq; /* If so, ->gp_seq to wait for. */ | ||
219 | unsigned long nocb_gp_loops; /* # passes through wait code. */ | ||
216 | struct swait_queue_head nocb_gp_wq; /* For nocb kthreads to sleep on. */ | 220 | struct swait_queue_head nocb_gp_wq; /* For nocb kthreads to sleep on. */ |
217 | bool nocb_cb_sleep; /* Is the nocb CB thread asleep? */ | 221 | bool nocb_cb_sleep; /* Is the nocb CB thread asleep? */ |
218 | struct task_struct *nocb_cb_kthread; | 222 | struct task_struct *nocb_cb_kthread; |
@@ -438,6 +442,7 @@ static void do_nocb_deferred_wakeup(struct rcu_data *rdp); | |||
438 | static void rcu_boot_init_nocb_percpu_data(struct rcu_data *rdp); | 442 | static void rcu_boot_init_nocb_percpu_data(struct rcu_data *rdp); |
439 | static void rcu_spawn_cpu_nocb_kthread(int cpu); | 443 | static void rcu_spawn_cpu_nocb_kthread(int cpu); |
440 | static void __init rcu_spawn_nocb_kthreads(void); | 444 | static void __init rcu_spawn_nocb_kthreads(void); |
445 | static void show_rcu_nocb_state(struct rcu_data *rdp); | ||
441 | static void rcu_nocb_lock(struct rcu_data *rdp); | 446 | static void rcu_nocb_lock(struct rcu_data *rdp); |
442 | static void rcu_nocb_unlock(struct rcu_data *rdp); | 447 | static void rcu_nocb_unlock(struct rcu_data *rdp); |
443 | static void rcu_nocb_unlock_irqrestore(struct rcu_data *rdp, | 448 | static void rcu_nocb_unlock_irqrestore(struct rcu_data *rdp, |