Commit 40c3baa7 authored by Jianguo Wu's avatar Jianguo Wu Committed by Linus Torvalds

mm/arch: use NUMA_NO_NODE

Use more appropriate NUMA_NO_NODE instead of -1 in all archs' module_alloc()
Signed-off-by: default avatarJianguo Wu <wujianguo@huawei.com>
Acked-by: default avatarDavid Rientjes <rientjes@google.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 03b61ff3
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
void *module_alloc(unsigned long size) void *module_alloc(unsigned long size)
{ {
return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END, return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END,
GFP_KERNEL, PAGE_KERNEL_EXEC, -1, GFP_KERNEL, PAGE_KERNEL_EXEC, NUMA_NO_NODE,
__builtin_return_address(0)); __builtin_return_address(0));
} }
#endif #endif
......
...@@ -29,7 +29,7 @@ ...@@ -29,7 +29,7 @@
void *module_alloc(unsigned long size) void *module_alloc(unsigned long size)
{ {
return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END, return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END,
GFP_KERNEL, PAGE_KERNEL_EXEC, -1, GFP_KERNEL, PAGE_KERNEL_EXEC, NUMA_NO_NODE,
__builtin_return_address(0)); __builtin_return_address(0));
} }
......
...@@ -219,7 +219,7 @@ void *module_alloc(unsigned long size) ...@@ -219,7 +219,7 @@ void *module_alloc(unsigned long size)
* init_data correctly */ * init_data correctly */
return __vmalloc_node_range(size, 1, VMALLOC_START, VMALLOC_END, return __vmalloc_node_range(size, 1, VMALLOC_START, VMALLOC_END,
GFP_KERNEL | __GFP_HIGHMEM, GFP_KERNEL | __GFP_HIGHMEM,
PAGE_KERNEL_RWX, -1, PAGE_KERNEL_RWX, NUMA_NO_NODE,
__builtin_return_address(0)); __builtin_return_address(0));
} }
......
...@@ -50,7 +50,7 @@ void *module_alloc(unsigned long size) ...@@ -50,7 +50,7 @@ void *module_alloc(unsigned long size)
if (PAGE_ALIGN(size) > MODULES_LEN) if (PAGE_ALIGN(size) > MODULES_LEN)
return NULL; return NULL;
return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END, return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END,
GFP_KERNEL, PAGE_KERNEL, -1, GFP_KERNEL, PAGE_KERNEL, NUMA_NO_NODE,
__builtin_return_address(0)); __builtin_return_address(0));
} }
#endif #endif
......
...@@ -29,7 +29,7 @@ static void *module_map(unsigned long size) ...@@ -29,7 +29,7 @@ static void *module_map(unsigned long size)
if (PAGE_ALIGN(size) > MODULES_LEN) if (PAGE_ALIGN(size) > MODULES_LEN)
return NULL; return NULL;
return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END, return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END,
GFP_KERNEL, PAGE_KERNEL, -1, GFP_KERNEL, PAGE_KERNEL, NUMA_NO_NODE,
__builtin_return_address(0)); __builtin_return_address(0));
} }
#else #else
......
...@@ -49,7 +49,7 @@ void *module_alloc(unsigned long size) ...@@ -49,7 +49,7 @@ void *module_alloc(unsigned long size)
return NULL; return NULL;
return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END, return __vmalloc_node_range(size, 1, MODULES_VADDR, MODULES_END,
GFP_KERNEL | __GFP_HIGHMEM, PAGE_KERNEL_EXEC, GFP_KERNEL | __GFP_HIGHMEM, PAGE_KERNEL_EXEC,
-1, __builtin_return_address(0)); NUMA_NO_NODE, __builtin_return_address(0));
} }
#ifdef CONFIG_X86_32 #ifdef CONFIG_X86_32
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment