]> git.baikalelectronics.ru Git - kernel.git/commit
srcu: Expedite srcu_schedule_cbs_snp() callback invocation
authorPaul E. McKenney <paulmck@linux.vnet.ibm.com>
Tue, 18 Apr 2017 17:28:31 +0000 (10:28 -0700)
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>
Fri, 21 Apr 2017 12:59:27 +0000 (05:59 -0700)
commitf8963478c3d3e2ed26c401f6e9e195533078d9d7
tree93c01ac25a12ce28f787fe7849887cdf53223a15
parentf37421e082095eb9486a68cbb120114eae0d0fb6
srcu: Expedite srcu_schedule_cbs_snp() callback invocation

Although Tree SRCU does reduce delays when there is at least one
synchronize_srcu_expedited() invocation pending, srcu_schedule_cbs_snp()
still waits for SRCU_INTERVAL before invoking callbacks.  Since
synchronize_srcu_expedited() now posts a callback and waits for
that callback to do a wakeup, this destroys the expedited nature of
synchronize_srcu_expedited().  This destruction became apparent to
Marc Zyngier in the guise of a guest-OS bootup slowdown from five
seconds to no fewer than forty seconds.

This commit therefore invokes callbacks immediately at the end of the
grace period when there is at least one synchronize_srcu_expedited()
invocation pending.  This brought Marc's guest-OS bootup times back
into the realm of reason.

Reported-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Tested-by: Marc Zyngier <marc.zyngier@arm.com>
kernel/rcu/srcutree.c