]> git.karo-electronics.de Git - linux-beck.git/commitdiff
rcu: Fix comment about _rcu_barrier()/orphanage exclusion
authorPaul E. McKenney <paul.mckenney@linaro.org>
Thu, 20 Sep 2012 23:59:47 +0000 (16:59 -0700)
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>
Tue, 23 Oct 2012 21:46:47 +0000 (14:46 -0700)
In the old days, _rcu_barrier() acquired ->onofflock to exclude
rcu_send_cbs_to_orphanage(), which allowed the latter to avoid memory
barriers in callback handling.  However, _rcu_barrier() recently started
doing get_online_cpus() to lock out CPU-hotplug operations entirely, which
means that the comment in rcu_send_cbs_to_orphanage() that talks about
->onofflock is now obsolete.  This commit therefore fixes the comment.

Signed-off-by: Paul E. McKenney <paul.mckenney@linaro.org>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
kernel/rcutree.c

index 74df86bd9204aef5ec9d14ca8b4b0094777bef87..ac8aed8ee4175ad7e6d039a043dda76150255853 100644 (file)
@@ -1581,8 +1581,8 @@ rcu_send_cbs_to_orphanage(int cpu, struct rcu_state *rsp,
 {
        /*
         * Orphan the callbacks.  First adjust the counts.  This is safe
-        * because ->onofflock excludes _rcu_barrier()'s adoption of
-        * the callbacks, thus no memory barrier is required.
+        * because _rcu_barrier() excludes CPU-hotplug operations, so it
+        * cannot be running now.  Thus no memory barrier is required.
         */
        if (rdp->nxtlist != NULL) {
                rsp->qlen_lazy += rdp->qlen_lazy;