LF OS
Hobby operating system for amd64 with high ambitions
|
Go to the source code of this file.
Data Structures | |
struct | mm_page_list_entry_t |
Macros | |
#define | PRESENT_BIT 1 |
Functions | |
void | mm_del_page_list_entry (mm_page_list_entry_t *entry) |
void * | mm_alloc_pages (uint64_t count) |
mm_page_list_entry_t * | mm_get_page_list_entry (mm_page_list_entry_t *start) |
void | mm_bootstrap (ptr_t usable_page) |
void | mm_mark_physical_pages (ptr_t start, uint64_t count, mm_page_status_t status) |
void | mm_print_physical_free_regions (void) |
ptr_t | mm_highest_address (void) |
Variables | |
mm_page_list_entry_t * | mm_physical_page_list = 0 |
struct mm_page_list_entry_t |
Data Fields | ||
---|---|---|
uint64_t | count | |
void * | next | |
ptr_t | start | |
mm_page_status_t | status |
void * mm_alloc_pages | ( | uint64_t | count | ) |
Definition at line 24 of file mm.c.
References mm_page_list_entry_t::count, mm_del_page_list_entry(), MM_FREE, mm_physical_page_list, mm_page_list_entry_t::next, panic_message(), mm_page_list_entry_t::start, and mm_page_list_entry_t::status.
void mm_bootstrap | ( | ptr_t | usable_page | ) |
Definition at line 76 of file mm.c.
References mm_page_list_entry_t::count, mm_physical_page_list, MM_UNKNOWN, mm_page_list_entry_t::next, mm_page_list_entry_t::start, and mm_page_list_entry_t::status.
void mm_del_page_list_entry | ( | mm_page_list_entry_t * | entry | ) |
Definition at line 18 of file mm.c.
References entry, MM_UNKNOWN, and mm_page_list_entry_t::start.
mm_page_list_entry_t * mm_get_page_list_entry | ( | mm_page_list_entry_t * | start | ) |
Definition at line 48 of file mm.c.
References ALLOCATOR_REGION_KERNEL_HEAP, mm_page_list_entry_t::count, MM_UNKNOWN, mm_page_list_entry_t::next, mm_page_list_entry_t::start, mm_page_list_entry_t::status, vm_context_alloc_pages(), and VM_KERNEL_CONTEXT.
ptr_t mm_highest_address | ( | void | ) |
Definition at line 166 of file mm.c.
References mm_page_list_entry_t::count, mm_physical_page_list, mm_page_list_entry_t::next, and mm_page_list_entry_t::start.
void mm_mark_physical_pages | ( | ptr_t | start, |
uint64_t | count, | ||
mm_page_status_t | status | ||
) |
Mark physical pages with information from loader memory map
start | Start of the physical memory region to mark |
count | Number of pages |
status | Page status of the given memory region |
Definition at line 93 of file mm.c.
References mm_page_list_entry_t::count, entry, mm_bootstrap(), mm_del_page_list_entry(), MM_FREE, mm_get_page_list_entry(), mm_physical_page_list, mm_page_list_entry_t::next, panic_message(), mm_page_list_entry_t::start, and mm_page_list_entry_t::status.
void mm_print_physical_free_regions | ( | void | ) |
Definition at line 154 of file mm.c.
References mm_page_list_entry_t::count, logd, MM_FREE, mm_physical_page_list, mm_page_list_entry_t::next, mm_page_list_entry_t::start, and mm_page_list_entry_t::status.
mm_page_list_entry_t* mm_physical_page_list = 0 |