matos/arch/x86/paging.h

16 lines
401 B
C
Raw Normal View History

2018-11-11 23:04:23 +01:00
#pragma once
#include "types.h"
2021-10-26 22:29:51 +02:00
#define PAGING_MEM_USER (1U << 0)
2019-04-11 22:34:20 +02:00
#define PAGING_MEM_READ (1U << 1)
#define PAGING_MEM_WRITE (1U << 2)
2018-11-12 23:01:55 +01:00
2021-04-10 00:24:02 +02:00
int pagingSetup(paddr_t lowerKernelAddr, paddr_t upperKernelAddr);
2018-11-12 21:32:04 +01:00
int pageMap(vaddr_t vaddr, paddr_t paddr, int flags);
2018-11-12 23:07:59 +01:00
int pageUnmap(vaddr_t vaddr);
unsigned long getNbMappedPage(void);
2021-10-26 22:52:24 +02:00
paddr_t pagingGetPaddr(vaddr_t vaddr);
paddr_t pagingGetCurrentPDPaddr();