diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2009-12-02 15:10:13 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-12-03 05:34:26 -0500 |
commit | d3f6bad3911736e44ba11f3f3f6ac4e8c837fdfc (patch) | |
tree | 55b0c2e11ab3ec02e9065cf3d46ffd20386dfed2 /kernel/rcutree_plugin.h | |
parent | 6ebb237bece23275d1da149b61a342f0d4d06a08 (diff) |
rcu: Rename "quiet" functions
The number of "quiet" functions has grown recently, and the
names are no longer very descriptive. The point of all of these
functions is to do some portion of the task of reporting a
quiescent state, so rename them accordingly:
o cpu_quiet() becomes rcu_report_qs_rdp(), which reports a
quiescent state to the per-CPU rcu_data structure. If this
turns out to be a new quiescent state for this grace period,
then rcu_report_qs_rnp() will be invoked to propagate the
quiescent state up the rcu_node hierarchy.
o cpu_quiet_msk() becomes rcu_report_qs_rnp(), which reports
a quiescent state for a given CPU (or possibly a set of CPUs)
up the rcu_node hierarchy.
o cpu_quiet_msk_finish() becomes rcu_report_qs_rsp(), which
reports a full set of quiescent states to the global rcu_state
structure.
o task_quiet() becomes rcu_report_unblock_qs_rnp(), which reports
a quiescent state due to a task exiting an RCU read-side critical
section that had previously blocked in that same critical section.
As indicated by the new name, this type of quiescent state is
reported up the rcu_node hierarchy (using rcu_report_qs_rnp()
to do so).
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Acked-by: Josh Triplett <josh@joshtriplett.org>
Acked-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Cc: dipankar@in.ibm.com
Cc: mathieu.desnoyers@polymtl.ca
Cc: dvhltc@us.ibm.com
Cc: niv@us.ibm.com
Cc: peterz@infradead.org
Cc: rostedt@goodmis.org
Cc: Valdis.Kletnieks@vt.edu
Cc: dhowells@redhat.com
LKML-Reference: <12597846163698-git-send-email->
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/rcutree_plugin.h')
-rw-r--r-- | kernel/rcutree_plugin.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/kernel/rcutree_plugin.h b/kernel/rcutree_plugin.h index 1d295c789d3d..c9f0c975c003 100644 --- a/kernel/rcutree_plugin.h +++ b/kernel/rcutree_plugin.h | |||
@@ -167,7 +167,7 @@ static int rcu_preempted_readers(struct rcu_node *rnp) | |||
167 | * irqs disabled, and this lock is released upon return, but irqs remain | 167 | * irqs disabled, and this lock is released upon return, but irqs remain |
168 | * disabled. | 168 | * disabled. |
169 | */ | 169 | */ |
170 | static void task_quiet(struct rcu_node *rnp, unsigned long flags) | 170 | static void rcu_report_unblock_qs_rnp(struct rcu_node *rnp, unsigned long flags) |
171 | __releases(rnp->lock) | 171 | __releases(rnp->lock) |
172 | { | 172 | { |
173 | unsigned long mask; | 173 | unsigned long mask; |
@@ -185,7 +185,7 @@ static void task_quiet(struct rcu_node *rnp, unsigned long flags) | |||
185 | * or tasks were kicked up to root rcu_node due to | 185 | * or tasks were kicked up to root rcu_node due to |
186 | * CPUs going offline. | 186 | * CPUs going offline. |
187 | */ | 187 | */ |
188 | cpu_quiet_msk_finish(&rcu_preempt_state, flags); | 188 | rcu_report_qs_rsp(&rcu_preempt_state, flags); |
189 | return; | 189 | return; |
190 | } | 190 | } |
191 | 191 | ||
@@ -193,7 +193,7 @@ static void task_quiet(struct rcu_node *rnp, unsigned long flags) | |||
193 | mask = rnp->grpmask; | 193 | mask = rnp->grpmask; |
194 | spin_unlock(&rnp->lock); /* irqs remain disabled. */ | 194 | spin_unlock(&rnp->lock); /* irqs remain disabled. */ |
195 | spin_lock(&rnp_p->lock); /* irqs already disabled. */ | 195 | spin_lock(&rnp_p->lock); /* irqs already disabled. */ |
196 | cpu_quiet_msk(mask, &rcu_preempt_state, rnp_p, flags); | 196 | rcu_report_qs_rnp(mask, &rcu_preempt_state, rnp_p, flags); |
197 | } | 197 | } |
198 | 198 | ||
199 | /* | 199 | /* |
@@ -253,12 +253,12 @@ static void rcu_read_unlock_special(struct task_struct *t) | |||
253 | /* | 253 | /* |
254 | * If this was the last task on the current list, and if | 254 | * If this was the last task on the current list, and if |
255 | * we aren't waiting on any CPUs, report the quiescent state. | 255 | * we aren't waiting on any CPUs, report the quiescent state. |
256 | * Note that task_quiet() releases rnp->lock. | 256 | * Note that rcu_report_unblock_qs_rnp() releases rnp->lock. |
257 | */ | 257 | */ |
258 | if (empty) | 258 | if (empty) |
259 | spin_unlock_irqrestore(&rnp->lock, flags); | 259 | spin_unlock_irqrestore(&rnp->lock, flags); |
260 | else | 260 | else |
261 | task_quiet(rnp, flags); | 261 | rcu_report_unblock_qs_rnp(rnp, flags); |
262 | } else { | 262 | } else { |
263 | local_irq_restore(flags); | 263 | local_irq_restore(flags); |
264 | } | 264 | } |
@@ -566,7 +566,7 @@ static int rcu_preempted_readers(struct rcu_node *rnp) | |||
566 | #ifdef CONFIG_HOTPLUG_CPU | 566 | #ifdef CONFIG_HOTPLUG_CPU |
567 | 567 | ||
568 | /* Because preemptible RCU does not exist, no quieting of tasks. */ | 568 | /* Because preemptible RCU does not exist, no quieting of tasks. */ |
569 | static void task_quiet(struct rcu_node *rnp, unsigned long flags) | 569 | static void rcu_report_unblock_qs_rnp(struct rcu_node *rnp, unsigned long flags) |
570 | { | 570 | { |
571 | spin_unlock_irqrestore(&rnp->lock, flags); | 571 | spin_unlock_irqrestore(&rnp->lock, flags); |
572 | } | 572 | } |