vm: add vm-object to represent non-contiguous physical memory allocations

vm-object can be used to demand-allocate non-contiguous physical memory, and
will provide an api for userspace programs to do the same. unless a vm-object
is created in-place (i.e. to represent a specific area of physical memory),
its memory pages are only allocated when the object is mapped AND someone
attempts to access the memory.
This commit is contained in:
2026-02-08 12:56:43 +00:00
parent 14ebcd4875
commit b8ccffd2d4
3 changed files with 283 additions and 0 deletions

View File

@@ -3,6 +3,7 @@
#include <mango/memblock.h>
#include <mango/printk.h>
#include <mango/status.h>
#include <mango/vm-object.h>
#include <mango/vm.h>
#include <stddef.h>
#include <stdint.h>
@@ -39,6 +40,7 @@ kern_status_t vm_bootstrap(
}
kmalloc_init();
vm_object_type_init();
return KERN_OK;
}