mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 04:34:03 +02:00
rcutorture: Make RCU Tasks Trace track Reader Batches
This commit adds the ->get_sp_seq and ->gp_diff fields to the tasks_tracing_ops structure so that RCU Tasks Trace rcutorture runs will track Reader Batch. Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
This commit is contained in:
parent
560b35bd7c
commit
86fa5387b4
|
|
@ -198,10 +198,13 @@ static inline void rcu_tasks_trace_expedite_current(void)
|
|||
srcu_expedite_current(&rcu_tasks_trace_srcu_struct);
|
||||
}
|
||||
|
||||
unsigned long rcu_tasks_trace_batches_completed(void);
|
||||
|
||||
// Placeholders to enable stepwise transition.
|
||||
void __init rcu_tasks_trace_suppress_unused(void);
|
||||
|
||||
#else
|
||||
static inline unsigned long rcu_tasks_trace_batches_completed(void) { return 0; }
|
||||
/*
|
||||
* The BPF JIT forms these addresses even when it doesn't call these
|
||||
* functions, so provide definitions that result in runtime errors.
|
||||
|
|
|
|||
|
|
@ -1252,7 +1252,8 @@ static struct rcu_torture_ops tasks_tracing_ops = {
|
|||
.read_delay = srcu_read_delay, /* just reuse srcu's version. */
|
||||
.readunlock = tasks_tracing_torture_read_unlock,
|
||||
.readlock_held = rcu_read_lock_trace_held,
|
||||
.get_gp_seq = rcu_no_completed,
|
||||
.get_gp_seq = rcu_tasks_trace_batches_completed,
|
||||
.gp_diff = rcu_seq_diff,
|
||||
.deferred_free = rcu_tasks_tracing_torture_deferred_free,
|
||||
.sync = synchronize_rcu_tasks_trace,
|
||||
.exp_sync = synchronize_rcu_tasks_trace,
|
||||
|
|
|
|||
|
|
@ -1606,4 +1606,10 @@ static inline void rcu_tasks_bootup_oddness(void) {}
|
|||
DEFINE_SRCU_FAST(rcu_tasks_trace_srcu_struct);
|
||||
EXPORT_SYMBOL_GPL(rcu_tasks_trace_srcu_struct);
|
||||
|
||||
unsigned long rcu_tasks_trace_batches_completed(void)
|
||||
{
|
||||
return srcu_batches_completed(&rcu_tasks_trace_srcu_struct);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(rcu_tasks_trace_batches_completed);
|
||||
|
||||
#endif /* #else #ifdef CONFIG_TASKS_TRACE_RCU */
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user