Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fdd2e5f8 authored by Adrian Bunk's avatar Adrian Bunk Committed by Linus Torvalds
Browse files

make mm/rmap.c:anon_vma_cachep static



This patch makes the needlessly global anon_vma_cachep static.

Signed-off-by: default avatarAdrian Bunk <bunk@kernel.org>
Reviewed-by: default avatarKOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
Acked-by: default avatarRik van Riel <riel@redhat.com>
Acked-by: default avatarHugh Dickins <hugh@veritas.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 1a651a00
Loading
Loading
Loading
Loading
+0 −12
Original line number Diff line number Diff line
@@ -39,18 +39,6 @@ struct anon_vma {

#ifdef CONFIG_MMU

extern struct kmem_cache *anon_vma_cachep;

static inline struct anon_vma *anon_vma_alloc(void)
{
	return kmem_cache_alloc(anon_vma_cachep, GFP_KERNEL);
}

static inline void anon_vma_free(struct anon_vma *anon_vma)
{
	kmem_cache_free(anon_vma_cachep, anon_vma);
}

static inline void anon_vma_lock(struct vm_area_struct *vma)
{
	struct anon_vma *anon_vma = vma->anon_vma;
+11 −1
Original line number Diff line number Diff line
@@ -55,7 +55,17 @@

#include "internal.h"

struct kmem_cache *anon_vma_cachep;
static struct kmem_cache *anon_vma_cachep;

static inline struct anon_vma *anon_vma_alloc(void)
{
	return kmem_cache_alloc(anon_vma_cachep, GFP_KERNEL);
}

static inline void anon_vma_free(struct anon_vma *anon_vma)
{
	kmem_cache_free(anon_vma_cachep, anon_vma);
}

/**
 * anon_vma_prepare - attach an anon_vma to a memory region