aboutsummaryrefslogtreecommitdiff
path: root/include/apos/vmem.h
diff options
context:
space:
mode:
Diffstat (limited to 'include/apos/vmem.h')
-rw-r--r--include/apos/vmem.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/apos/vmem.h b/include/apos/vmem.h
index 663b2ab..1451c82 100644
--- a/include/apos/vmem.h
+++ b/include/apos/vmem.h
@@ -16,6 +16,7 @@ vm_t alloc_fixed_uvmem(struct tcb *r, vm_t start, size_t size, vmflags_t flags);
vm_t alloc_shared_uvmem(struct tcb *r, size_t size, vmflags_t flags);
vm_t ref_shared_uvmem(struct tcb *r1, struct tcb *r2, vm_t va, vmflags_t flags);
+stat_t clear_uvmem(struct tcb *r, bool force);
stat_t free_uvmem(struct tcb *r, vm_t a);
stat_t init_uvmem(struct tcb *r, vm_t base, vm_t top);
@@ -25,6 +26,8 @@ stat_t alloc_uvmem_wrapper(struct vmem *b, pm_t *offset, vm_t vaddr,
vmflags_t flags, enum mm_order order, void *data);
stat_t alloc_shared_wrapper(struct vmem *b, pm_t *offset, vm_t vaddr,
vmflags_t flags, enum mm_order order, void *data);
+stat_t clone_allocd_wrapper(struct vmem *b, pm_t *offset, vm_t vaddr,
+ vmflags_t flags, enum mm_order order, void *data);
stat_t free_uvmem_wrapper(struct vmem *b, pm_t *offset, vm_t vaddr,
vmflags_t flags, enum mm_order order, void *data);
@@ -34,6 +37,9 @@ stat_t free_uvmem_wrapper(struct vmem *b, pm_t *offset, vm_t vaddr,
#define map_shared_region(b, start, bytes, flags, data) \
map_fill_region(b, &alloc_shared_wrapper, 0, start, bytes, flags, data)
+#define clone_allocd_region(b, start, bytes, flags, data) \
+ map_fill_region(b, &clone_allocd_wrapper, 0, start, bytes, flags, data)
+
#define unmap_freed_region(b, start, bytes, flags, data) \
map_fill_region(b, &free_uvmem_wrapper, 0, start, bytes, flags, data)