Re: [PATCH tip/core/urgent 1/7] rcu: decrease rcu_report_exp_rnpcoupling with scheduler
From: Peter Zijlstra
Date: Tue Jul 19 2011 - 22:41:29 EST
On Tue, 2011-07-19 at 17:18 -0700, Paul E. McKenney wrote:
> +++ b/kernel/rcutree_plugin.h
> @@ -696,8 +696,10 @@ static void rcu_report_exp_rnp(struct rcu_state *rsp, struct rcu_node *rnp)
> raw_spin_lock_irqsave(&rnp->lock, flags);
> for (;;) {
> if (!sync_rcu_preempt_exp_done(rnp))
> + raw_spin_unlock_irqrestore(&rnp->lock, flags);
> break;
I bet that'll all work much better if you wrap it in curly braces like:
if (!sync_rcu_preempt_exp_done(rnp)) {
raw_spin_unlock_irqrestore(&rnp->lock, flags);
break;
}
That might also explain those explosions Ed and Ben have been seeing.
> if (rnp->parent == NULL) {
> + raw_spin_unlock_irqrestore(&rnp->lock, flags);
> wake_up(&sync_rcu_preempt_exp_wq);
> break;
> }
> @@ -707,7 +709,6 @@ static void rcu_report_exp_rnp(struct rcu_state *rsp, struct rcu_node *rnp)
> raw_spin_lock(&rnp->lock); /* irqs already disabled */
> rnp->expmask &= ~mask;
> }
> - raw_spin_unlock_irqrestore(&rnp->lock, flags);
> }
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/