]> asedeno.scripts.mit.edu Git - linux.git/commit
rcu/nocb: Reduce contention at no-CBs invocation-done time
authorPaul E. McKenney <paulmck@linux.ibm.com>
Sat, 1 Jun 2019 20:33:55 +0000 (13:33 -0700)
committerPaul E. McKenney <paulmck@linux.ibm.com>
Tue, 13 Aug 2019 21:35:49 +0000 (14:35 -0700)
commit523bddd553c09a2cf051eb724bffba680424f5ec
tree575f1bed80f45d6507d2c5533f4ede50c5b7ffb1
parent6608c3a027bcc0b34cc02bc764ea9f52b9dce46f
rcu/nocb: Reduce contention at no-CBs invocation-done time

Currently, nocb_cb_wait() unconditionally acquires the leaf rcu_node
->lock to advance callbacks when done invoking the previous batch.
It does this while holding ->nocb_lock, which means that contention on
the leaf rcu_node ->lock visits itself on the ->nocb_lock.  This commit
therefore makes this lock acquisition conditional, forgoing callback
advancement when the leaf rcu_node ->lock is not immediately available.
(In this case, the no-CBs grace-period kthread will eventually do any
needed callback advancement.)

Signed-off-by: Paul E. McKenney <paulmck@linux.ibm.com>
kernel/rcu/tree_plugin.h