diff options
author | Lai Jiangshan | 2011-03-18 11:43:26 +0800 |
---|---|---|
committer | Paul E. McKenney | 2011-05-07 22:50:57 -0700 |
commit | dad178fcd5b295f5f350a46a5eaf2f28e847bb5a (patch) | |
tree | ce8a306e58a4b7b01e95b2372705099a29fbf0b4 /net/core | |
parent | bceb0f4512d448763fe98c9f37504c98bbebbed6 (diff) |
net,rcu: convert call_rcu(__gen_kill_estimator) to kfree_rcu()
The rcu callback __gen_kill_estimator() just calls a kfree(),
so we use kfree_rcu() instead of the call_rcu(__gen_kill_estimator).
Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/gen_estimator.c | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/net/core/gen_estimator.c b/net/core/gen_estimator.c index 7c2373321b74..43b03dd71e85 100644 --- a/net/core/gen_estimator.c +++ b/net/core/gen_estimator.c @@ -249,13 +249,6 @@ int gen_new_estimator(struct gnet_stats_basic_packed *bstats, } EXPORT_SYMBOL(gen_new_estimator); -static void __gen_kill_estimator(struct rcu_head *head) -{ - struct gen_estimator *e = container_of(head, - struct gen_estimator, e_rcu); - kfree(e); -} - /** * gen_kill_estimator - remove a rate estimator * @bstats: basic statistics @@ -279,7 +272,7 @@ void gen_kill_estimator(struct gnet_stats_basic_packed *bstats, write_unlock(&est_lock); list_del_rcu(&e->list); - call_rcu(&e->e_rcu, __gen_kill_estimator); + kfree_rcu(e, e_rcu); } spin_unlock_bh(&est_tree_lock); } |