rcu: Make synchronize_srcu_expedited() fast if running readers
The synchronize_srcu_expedited() function is currently quick if there
are no active readers, but will delay a full jiffy if there are any.
If these readers leave their SRCU read-side critical sections quickly,
this is way too long to wait. So this commit first waits ten microseconds,
and only then falls back to jiffy-at-a-time waiting.
Reported-by: Avi Kivity <[email protected]>
Reported-by: Marcelo Tosatti <[email protected]>
Tested-by: Takuya Yoshikawa <[email protected]>
Signed-off-by: Paul E. McKenney <[email protected]>
2 files changed