Le Wed, Jun 24, 2026 at 06:23:51AM -0700, Puranjay Mohan a écrit :
> rcu_pending() decides whether rcu_core() should run on the current CPU's
> timer tick.  It does not account for expedited grace periods: after an
> expedited GP completes, a non-offloaded CPU's callbacks remain in
> RCU_WAIT_TAIL (not yet advanced to RCU_DONE_TAIL) and rcu_core() is
> never invoked to advance them.
> 
> Detect that case via rcu_segcblist_nextgp() combined with a new
> memory-ordering-free poll variant,
> poll_state_synchronize_rcu_full_unordered().  This keeps rcu_pending()
> cheap: it runs on every tick that has pending callbacks, so it must
> not pay for the two memory barriers in
> poll_state_synchronize_rcu_full().  The check is only a hint to run
> rcu_core(); the ordered re-check and the actual callback advancement
> happen there.
> 
> Signed-off-by: Puranjay Mohan <[email protected]>

Reviewed-by: Frederic Weisbecker <[email protected]>

-- 
Frederic Weisbecker
SUSE Labs

Reply via email to