fix: setup recursive paging in process

This commit is contained in:
2025-11-28 20:06:27 +01:00
parent d46fe337c1
commit 24dce6e737

View File

@ -5,6 +5,7 @@
#include "thread.h"
#include "string.h"
#include <stdint.h>
struct pcb *create_process(uid_t uid)
{
@ -24,6 +25,7 @@ struct pcb *create_process(uid_t uid)
new_pcb->cr3 =
(void *)((uint32_t)VA2PTE((uint32_t)new_pcb->heap) & PAGE_MASK);
memcpy(new_pcb->heap, PD, 4096);
new_pcb->heap[1023] = (uint32_t) new_pcb->cr3 | INIT_FLAGS;
new_pcb->daddy = NULL;
new_pcb->children = NULL;