mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-11-27 01:11:31 +00:00
rcu: Distinguish between NOCB and non-NOCB rcu_callback trace events
One way to distinguish between NOCB and non-NOCB rcu_callback trace events is that the former always print zero for the lazy and non-lazy queue lengths. Unfortunately, this also means that we cannot see the NOCB queue lengths. This commit therefore accesses the NOCB queue lengths, but negates them. NOCB rcu_callback trace events should therefore have negative queue lengths. Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com> [ paulmck: Match operand size per kbuild test robot's advice. ]
This commit is contained in:
parent
9261dd0da6
commit
756cbf6bef
1 changed files with 4 additions and 2 deletions
|
|
@ -2147,10 +2147,12 @@ static bool __call_rcu_nocb(struct rcu_data *rdp, struct rcu_head *rhp,
|
||||||
if (__is_kfree_rcu_offset((unsigned long)rhp->func))
|
if (__is_kfree_rcu_offset((unsigned long)rhp->func))
|
||||||
trace_rcu_kfree_callback(rdp->rsp->name, rhp,
|
trace_rcu_kfree_callback(rdp->rsp->name, rhp,
|
||||||
(unsigned long)rhp->func,
|
(unsigned long)rhp->func,
|
||||||
rdp->qlen_lazy, rdp->qlen);
|
-atomic_long_read(&rdp->nocb_q_count_lazy),
|
||||||
|
-atomic_long_read(&rdp->nocb_q_count));
|
||||||
else
|
else
|
||||||
trace_rcu_callback(rdp->rsp->name, rhp,
|
trace_rcu_callback(rdp->rsp->name, rhp,
|
||||||
rdp->qlen_lazy, rdp->qlen);
|
-atomic_long_read(&rdp->nocb_q_count_lazy),
|
||||||
|
-atomic_long_read(&rdp->nocb_q_count));
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue