summaryrefslogtreecommitdiff
path: root/include/linux/rcu_segcblist.h
diff options
context:
space:
mode:
authorJoel Fernandes (Google) <joel@joelfernandes.org>2020-09-23 18:22:09 +0300
committerPaul E. McKenney <paulmck@kernel.org>2021-01-07 03:24:19 +0300
commitae5c2341ed3987bd434ed495bd4f3d8b2bc3e623 (patch)
tree07962aabd3b1bdbd31870c53b4880f4f49f5fec6 /include/linux/rcu_segcblist.h
parentc2e13112e830c06825339cbadf0b3bc2bdb9a716 (diff)
downloadlinux-ae5c2341ed3987bd434ed495bd4f3d8b2bc3e623.tar.xz
rcu/segcblist: Add counters to segcblist datastructure
Add counting of segment lengths of segmented callback list. This will be useful for a number of things such as knowing how big the ready-to-execute segment have gotten. The immediate benefit is ability to trace how the callbacks in the segmented callback list change. Also this patch remove hacks related to using donecbs's ->len field as a temporary variable to save the segmented callback list's length. This cannot be done anymore and is not needed. Also fix SRCU: The negative counting of the unsegmented list cannot be used to adjust the segmented one. To fix this, sample the unsegmented length in advance, and use it after CB execution to adjust the segmented list's length. Reviewed-by: Frederic Weisbecker <frederic@kernel.org> Signed-off-by: Joel Fernandes (Google) <joel@joelfernandes.org> Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
Diffstat (limited to 'include/linux/rcu_segcblist.h')
-rw-r--r--include/linux/rcu_segcblist.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/rcu_segcblist.h b/include/linux/rcu_segcblist.h
index b36afe7b22c9..6c01f09a6456 100644
--- a/include/linux/rcu_segcblist.h
+++ b/include/linux/rcu_segcblist.h
@@ -72,6 +72,7 @@ struct rcu_segcblist {
#else
long len;
#endif
+ long seglen[RCU_CBLIST_NSEGS];
u8 enabled;
u8 offloaded;
};