2023-01-12 13:20:38 +02:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include <stddef.h>
|
|
|
|
#include <stdint.h>
|
|
|
|
|
|
|
|
class MMU
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
static void Intialize();
|
|
|
|
static MMU& Get();
|
|
|
|
|
|
|
|
void AllocatePage(uintptr_t);
|
|
|
|
void AllocateRange(uintptr_t, ptrdiff_t);
|
2023-01-12 13:45:01 +02:00
|
|
|
|
|
|
|
void UnAllocatePage(uintptr_t);
|
|
|
|
void UnAllocateRange(uintptr_t, ptrdiff_t);
|
|
|
|
|
2023-01-12 13:20:38 +02:00
|
|
|
private:
|
|
|
|
MMU();
|
|
|
|
|
|
|
|
private:
|
|
|
|
uint64_t* m_page_descriptor_pointer_table;
|
|
|
|
};
|