Skip to main content

Module mm

Module mm 

Source
Expand description

Memory management implementation

SV39 page-based virtual-memory architecture for RV64 systems, and everything about memory management, like frame allocator, page table, map area and memory set, is implemented here.

Every task or process has a memory_set to control its virtual memory.

Re-exportsยง

pub use address::PhysAddr;
pub use address::PhysPageNum;
pub use address::VirtAddr;
pub use address::VirtPageNum;
pub use frame_allocator::FrameTracker;
pub use frame_allocator::frame_alloc;
pub use memory_set::remap_test;
pub use memory_set::KERNEL_SPACE;
pub use memory_set::MapPermission;
pub use memory_set::MemorySet;
pub use page_table::PageTableEntry;
pub use page_table::translated_byte_buffer;

Modulesยง

address ๐Ÿ”’
Implementation of physical and virtual address and page number.
frame_allocator ๐Ÿ”’
Implementation of FrameAllocator which controls all the frames in the operating system.
heap_allocator ๐Ÿ”’
The global allocator
memory_set ๐Ÿ”’
Implementation of MapArea and MemorySet.
page_table ๐Ÿ”’
Implementation of PageTableEntry and PageTable.

Functionsยง

init
initiate heap allocator, frame allocator and kernel space