aboutsummaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-08-04 20:26:15 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2008-08-04 20:26:15 -0400
commit2e1e9212ed8c532c6b324de77d3cafef5d2bc846 (patch)
tree15097a99d03679f2c95ea2fdc0eb3c3ebcc474b8 /mm
parent2acb802b0c5485aedb46e23b2b45e49573454c09 (diff)
parentf5663f5bded3364158e2d31904173cb1debc2ecd (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: (29 commits) sh: enable maple_keyb in dreamcast_defconfig. SH2(A) cache update nommu: Provide vmalloc_exec(). add addrespace definition for sh2a. sh: Kill off ARCH_SUPPORTS_AOUT and remnants of a.out support. sh: define GENERIC_HARDIRQS_NO__DO_IRQ. sh: define GENERIC_LOCKBREAK. sh: Save NUMA node data in vmcore for crash dumps. sh: module_alloc() should be using vmalloc_exec(). sh: Fix up __bug_table handling in module loader. sh: Add documentation and integrate into docbook build. sh: Fix up broken kerneldoc comments. maple: Kill useless private_data pointer. maple: Clean up maple_driver_register/unregister routines. input: Clean up maple keyboard driver maple: allow removal and reinsertion of keyboard driver module sh: /proc/asids depends on MMU. arch/sh/boards/mach-se/7343/irq.c: removed duplicated #include arch/sh/boards/board-ap325rxa.c: removed duplicated #include sh/boards/Makefile typo fix ...
Diffstat (limited to 'mm')
-rw-r--r--mm/nommu.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/mm/nommu.c b/mm/nommu.c
index 5edccd9c9218..ed75bc962fbe 100644
--- a/mm/nommu.c
+++ b/mm/nommu.c
@@ -266,6 +266,27 @@ void *vmalloc_node(unsigned long size, int node)
266} 266}
267EXPORT_SYMBOL(vmalloc_node); 267EXPORT_SYMBOL(vmalloc_node);
268 268
269#ifndef PAGE_KERNEL_EXEC
270# define PAGE_KERNEL_EXEC PAGE_KERNEL
271#endif
272
273/**
274 * vmalloc_exec - allocate virtually contiguous, executable memory
275 * @size: allocation size
276 *
277 * Kernel-internal function to allocate enough pages to cover @size
278 * the page level allocator and map them into contiguous and
279 * executable kernel virtual space.
280 *
281 * For tight control over page level allocator and protection flags
282 * use __vmalloc() instead.
283 */
284
285void *vmalloc_exec(unsigned long size)
286{
287 return __vmalloc(size, GFP_KERNEL | __GFP_HIGHMEM, PAGE_KERNEL_EXEC);
288}
289
269/** 290/**
270 * vmalloc_32 - allocate virtually contiguous memory (32bit addressable) 291 * vmalloc_32 - allocate virtually contiguous memory (32bit addressable)
271 * @size: allocation size 292 * @size: allocation size