mirror of
https://github.com/Mathewnd/Astral.git
synced 2026-11-01 23:18:21 +00:00
kernel: rework init
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
#include <mutex.h>
|
||||
#include <util.h>
|
||||
#include <kernel/vmmcache.h>
|
||||
#include <kernel/init.h>
|
||||
|
||||
uintptr_t hhdmbase;
|
||||
static size_t memorysize;
|
||||
@@ -266,6 +267,11 @@ void pmm_init() {
|
||||
MUTEX_INIT(&freelistmutex);
|
||||
}
|
||||
|
||||
INIT_ROUTINE_DEFINE(pmm,
|
||||
INIT_ROUTINE_FLAGS_NONE,
|
||||
pmm_init,
|
||||
arch_early);
|
||||
|
||||
// XXX pmm_alloc won't be able to take pages from the page cache when the allocation size is over 1 page
|
||||
|
||||
void *pmm_alloc(size_t size, int section) {
|
||||
|
||||
Reference in New Issue
Block a user