* [PATCH 34/36] vmalloc,rcu: convert call_rcu(rcu_free_vb) to kfree_rcu()
@ 2011-03-18 4:13 Lai Jiangshan
0 siblings, 0 replies; only message in thread
From: Lai Jiangshan @ 2011-03-18 4:13 UTC (permalink / raw)
To: Paul E. McKenney, Ingo Molnar, Andrew Morton, David Rientjes,
Namhyung Kim, Pekka Enberg, Jeremy Fitzhardinge, linux-mm,
linux-kernel
The rcu callback rcu_free_vb() just calls a kfree(),
so we use kfree_rcu() instead of the call_rcu(rcu_free_vb).
Signed-off-by: Lai Jiangshan <laijs@cn.fujitsu.com>
---
mm/vmalloc.c | 9 +--------
1 files changed, 1 insertions(+), 8 deletions(-)
diff --git a/mm/vmalloc.c b/mm/vmalloc.c
index fe38e30..2f3c614 100644
--- a/mm/vmalloc.c
+++ b/mm/vmalloc.c
@@ -778,13 +778,6 @@ static struct vmap_block *new_vmap_block(gfp_t gfp_mask)
return vb;
}
-static void rcu_free_vb(struct rcu_head *head)
-{
- struct vmap_block *vb = container_of(head, struct vmap_block, rcu_head);
-
- kfree(vb);
-}
-
static void free_vmap_block(struct vmap_block *vb)
{
struct vmap_block *tmp;
@@ -797,7 +790,7 @@ static void free_vmap_block(struct vmap_block *vb)
BUG_ON(tmp != vb);
free_vmap_area_noflush(vb->va);
- call_rcu(&vb->rcu_head, rcu_free_vb);
+ kfree_rcu(vb, rcu_head);
}
static void purge_fragmented_blocks(int cpu)
--
1.7.4
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2011-03-18 4:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-18 4:13 [PATCH 34/36] vmalloc,rcu: convert call_rcu(rcu_free_vb) to kfree_rcu() Lai Jiangshan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).