vmm: fix lazy allocation

This commit is contained in:
Matheus
2023-05-08 22:16:53 -03:00
parent 1cb49908e2
commit cec3146bd5
+1 -1
View File
@@ -322,7 +322,7 @@ bool vmm_pagefault(void *addr, bool user, int actions) {
void *paddr = pmm_alloc(1, PMM_SECTION_DEFAULT);
__assert(paddr); // XXX handle these better than an assert once there are signals and such
__assert(arch_mmu_map(_cpu()->vmmctx->pagetable, paddr, addr, range->mmuflags));
memset(addr, 0, PAGE_SIZE);
memset(MAKE_HHDM(paddr), 0, PAGE_SIZE);
status = true;
}