diff options
author | Ingo Molnar <mingo@elte.hu> | 2008-11-11 09:40:18 +0100 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-11-11 09:40:18 +0100 |
commit | e0cb4ebcd9e5b4ddd8216c20f54445c91b1fa4b9 (patch) | |
tree | d1c3b22b7e9f02fb56927da530da09c6ee7ce0b9 /mm/vmalloc.c | |
parent | a309720c876d7ad2e224bfd1982c92ae4364c82e (diff) | |
parent | 45b86a96f17cb2900f291129b0e67287400e45b2 (diff) |
Merge branch 'tracing/urgent' into tracing/ftrace
Conflicts:
kernel/trace/trace.c
Diffstat (limited to 'mm/vmalloc.c')
-rw-r--r-- | mm/vmalloc.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/mm/vmalloc.c b/mm/vmalloc.c index f1cc03bbf6a..ba6b0f5f7fa 100644 --- a/mm/vmalloc.c +++ b/mm/vmalloc.c @@ -178,7 +178,7 @@ static int vmap_page_range(unsigned long addr, unsigned long end, static inline int is_vmalloc_or_module_addr(const void *x) { /* - * x86-64 and sparc64 put modules in a special place, + * ARM, x86-64 and sparc64 put modules in a special place, * and fall back on vmalloc() if that fails. Others * just put it in the vmalloc space. */ @@ -592,6 +592,8 @@ static void free_unmap_vmap_area_addr(unsigned long addr) #define VMAP_BLOCK_SIZE (VMAP_BBMAP_BITS * PAGE_SIZE) +static bool vmap_initialized __read_mostly = false; + struct vmap_block_queue { spinlock_t lock; struct list_head free; @@ -828,6 +830,9 @@ void vm_unmap_aliases(void) int cpu; int flush = 0; + if (unlikely(!vmap_initialized)) + return; + for_each_possible_cpu(cpu) { struct vmap_block_queue *vbq = &per_cpu(vmap_block_queue, cpu); struct vmap_block *vb; @@ -942,6 +947,8 @@ void __init vmalloc_init(void) INIT_LIST_HEAD(&vbq->dirty); vbq->nr_dirty = 0; } + + vmap_initialized = true; } void unmap_kernel_range(unsigned long addr, unsigned long size) |