rcu: Clarify fill-the-gap comment in rcu_segcblist_advance()
Reported-by: Frederic Weisbecker <frederic@kernel.org> Reported-by: Neeraj Upadhyay <quic_neeraju@quicinc.com> Reported-by: Boqun Feng <boqun.feng@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@kernel.org>
This commit is contained in:
parent
cfe43f478b
commit
d22959aa93
|
@ -505,10 +505,10 @@ void rcu_segcblist_advance(struct rcu_segcblist *rsclp, unsigned long seq)
|
||||||
WRITE_ONCE(rsclp->tails[j], rsclp->tails[RCU_DONE_TAIL]);
|
WRITE_ONCE(rsclp->tails[j], rsclp->tails[RCU_DONE_TAIL]);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Callbacks moved, so clean up the misordered ->tails[] pointers
|
* Callbacks moved, so there might be an empty RCU_WAIT_TAIL
|
||||||
* that now point into the middle of the list of ready-to-invoke
|
* and a non-empty RCU_NEXT_READY_TAIL. If so, copy the
|
||||||
* callbacks. The overall effect is to copy down the later pointers
|
* RCU_NEXT_READY_TAIL segment to fill the RCU_WAIT_TAIL gap
|
||||||
* into the gap that was created by the now-ready segments.
|
* created by the now-ready-to-invoke segments.
|
||||||
*/
|
*/
|
||||||
for (j = RCU_WAIT_TAIL; i < RCU_NEXT_TAIL; i++, j++) {
|
for (j = RCU_WAIT_TAIL; i < RCU_NEXT_TAIL; i++, j++) {
|
||||||
if (rsclp->tails[j] == rsclp->tails[RCU_NEXT_TAIL])
|
if (rsclp->tails[j] == rsclp->tails[RCU_NEXT_TAIL])
|
||||||
|
|
Loading…
Reference in New Issue