vm: implement private and shared address space mappings

whether a mapping is private or shared determines how the mapping is handled
when a task is duplicated.
This commit is contained in:
2026-04-21 21:12:00 +01:00
parent 8b7382fa13
commit 278fe39c0d
9 changed files with 63 additions and 24 deletions
+3
View File
@@ -22,6 +22,8 @@ struct vm_area {
struct address_space *vma_space;
/* used to link to vm_object->vo_mappings */
struct queue_entry vma_object_entry;
/* the memory control flags applied to this area */
vm_flags_t vma_flags;
/* the memory protection flags applied to this area */
vm_prot_t vma_prot;
/* offset in bytes to the start of the object data that was mapped */
@@ -83,6 +85,7 @@ extern kern_status_t address_space_map(
struct vm_object *object,
off_t object_offset,
size_t length,
vm_flags_t flags,
vm_prot_t prot,
virt_addr_t *out);
extern kern_status_t address_space_unmap(