summaryrefslogtreecommitdiffstats
path: root/sys/vm/vm_extern.h
diff options
context:
space:
mode:
authoralc <alc@FreeBSD.org>2009-06-17 17:19:48 +0000
committeralc <alc@FreeBSD.org>2009-06-17 17:19:48 +0000
commitb4d6ffe1f50458a3410494f445c048517efccc94 (patch)
tree645f687c5c92adb1dfc423f6cca74d4c9292981f /sys/vm/vm_extern.h
parent9693648e9f0e69680bb58ee23ca123771a52e947 (diff)
downloadFreeBSD-src-b4d6ffe1f50458a3410494f445c048517efccc94.zip
FreeBSD-src-b4d6ffe1f50458a3410494f445c048517efccc94.tar.gz
Refactor contigmalloc() into two functions: a simple front-end that deals
with the malloc tag and calls a new back-end, kmem_alloc_contig(), that allocates the pages and maps them. The motivations for this change are two-fold: (1) A cache mode parameter will be added to kmem_alloc_contig(). In other words, kmem_alloc_contig() will be extended to support the allocation of memory with caller-specified caching. (2) The UMA allocation function that is used by the two jumbo frames zones can use kmem_alloc_contig() in place of contigmalloc() and thereby avoid having free jumbo frames held by the zone counted as live malloc()ed memory.
Diffstat (limited to 'sys/vm/vm_extern.h')
-rw-r--r--sys/vm/vm_extern.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/vm/vm_extern.h b/sys/vm/vm_extern.h
index 475a20e..efd363a 100644
--- a/sys/vm/vm_extern.h
+++ b/sys/vm/vm_extern.h
@@ -44,6 +44,9 @@ struct vnode;
int kernacc(void *, int, int);
vm_offset_t kmem_alloc(vm_map_t, vm_size_t);
+vm_offset_t kmem_alloc_contig(vm_map_t map, vm_size_t size, int flags,
+ vm_paddr_t low, vm_paddr_t high, unsigned long alignment,
+ unsigned long boundary);
vm_offset_t kmem_alloc_nofault(vm_map_t, vm_size_t);
vm_offset_t kmem_alloc_wait(vm_map_t, vm_size_t);
void kmem_free(vm_map_t, vm_offset_t, vm_size_t);
OpenPOWER on IntegriCloud