PatchworkOS
Loading...
Searching...
No Matches
mem.h File Reference
#include <stdint.h>
#include <boot/boot_info.h>
#include <kernel/mem/paging_types.h>

Go to the source code of this file.

Macros

#define MEM_BASIC_ALLOCATOR_MIN_PAGES   8192
 The minimum amount of pages that we will reserve for the basic allocator.
 
#define MEM_BASIC_ALLOCATOR_RESERVE_PERCENTAGE   5
 The percentage of available memory that we will reserve for the basic allocator.
 

Functions

EFI_STATUS mem_init (void)
 Initializes the basic memory allocator.
 
EFI_STATUS mem_map_init (boot_memory_map_t *map)
 Initialize and load the memory map provided by the UEFI firmware.
 
void mem_map_deinit (boot_memory_map_t *map)
 Deinitializes the memory map and frees any allocated resources.
 
void mem_page_table_init (page_table_t *table, boot_memory_map_t *map, boot_gop_t *gop, boot_kernel_t *kernel)
 Initializes a page table for use by the kernel.