Message ID | 20100908121628.0eee5294@nehalam |
---|---|
State | Accepted, archived |
Delegated to: | David Miller |
Headers | show |
Le mercredi 08 septembre 2010 à 12:16 -0700, Stephen Hemminger a écrit : > But that commit adds unnecessary bh_disable > ------- Yes I mentioned it in the original patch discussion > Subject: [PATCH] pkt_sched: remov unnecessary bh_disable > > Now that est_tree_lock is acquired with BH protection, the other > call is unnecessary. > > Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> > > --- a/net/core/gen_estimator.c 2010-09-08 12:13:55.182851300 -0700 > +++ b/net/core/gen_estimator.c 2010-09-08 12:14:07.401063663 -0700 > @@ -274,9 +274,9 @@ void gen_kill_estimator(struct gnet_stat > while ((e = gen_find_node(bstats, rate_est))) { > rb_erase(&e->node, &est_root); > > - write_lock_bh(&est_lock); > + write_lock(&est_lock); > e->bstats = NULL; > - write_unlock_bh(&est_lock); > + write_unlock(&est_lock); > > list_del_rcu(&e->list); > call_rcu(&e->e_rcu, __gen_kill_estimator); > > > -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: Eric Dumazet <eric.dumazet@gmail.com> Date: Wed, 08 Sep 2010 21:23:03 +0200 > Le mercredi 08 septembre 2010 à 12:16 -0700, Stephen Hemminger a écrit : > >> But that commit adds unnecessary bh_disable >> ------- > > Yes I mentioned it in the original patch discussion I'll apply this to net-next-2.6 after my next merge of net-2.6 into net-next-2.6 -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
--- a/net/core/gen_estimator.c 2010-09-08 12:13:55.182851300 -0700 +++ b/net/core/gen_estimator.c 2010-09-08 12:14:07.401063663 -0700 @@ -274,9 +274,9 @@ void gen_kill_estimator(struct gnet_stat while ((e = gen_find_node(bstats, rate_est))) { rb_erase(&e->node, &est_root); - write_lock_bh(&est_lock); + write_lock(&est_lock); e->bstats = NULL; - write_unlock_bh(&est_lock); + write_unlock(&est_lock); list_del_rcu(&e->list); call_rcu(&e->e_rcu, __gen_kill_estimator);