Compare commits
No commits in common. "71b981175e04992a35c69e2d4da48c5ad8e9d997" and "519aa347dda687f24ab0928eaaafc30f48ea9825" have entirely different histories.
71b981175e
...
519aa347dd
@ -1,13 +1,18 @@
|
||||
#include "InitRD.h"
|
||||
#include "arch/MMU.h"
|
||||
#include "boot/bootboot.h"
|
||||
#include "memory/MemoryManager.h"
|
||||
#include <luna/Alignment.h>
|
||||
|
||||
TarStream g_initrd;
|
||||
extern const BOOTBOOT bootboot;
|
||||
|
||||
void InitRD::initialize()
|
||||
{
|
||||
u64 virtual_initrd_address = MMU::translate_physical_address(bootboot.initrd_ptr);
|
||||
u64 virtual_initrd_address =
|
||||
MemoryManager::get_kernel_mapping_for_frames(
|
||||
bootboot.initrd_ptr, get_blocks_from_size(bootboot.initrd_size, ARCH_PAGE_SIZE), MMU::NoExecute)
|
||||
.expect_value("Unable to map the initial ramdisk into virtual memory");
|
||||
|
||||
g_initrd.initialize((void*)virtual_initrd_address, bootboot.initrd_size);
|
||||
}
|
||||
|
@ -100,7 +100,7 @@ namespace MemoryManager
|
||||
void init()
|
||||
{
|
||||
init_physical_frame_allocator();
|
||||
|
||||
KernelVM::init();
|
||||
MMU::setup_initial_page_directory();
|
||||
|
||||
auto frame_bitmap = g_frame_bitmap.lock();
|
||||
@ -108,8 +108,6 @@ namespace MemoryManager
|
||||
|
||||
auto virtual_bitmap_base = MMU::translate_physical_address(phys);
|
||||
frame_bitmap->initialize((void*)virtual_bitmap_base, frame_bitmap->size_in_bytes());
|
||||
|
||||
KernelVM::init();
|
||||
}
|
||||
|
||||
void do_lock_frame(u64 index, Bitmap& bitmap)
|
||||
|
Loading…
Reference in New Issue
Block a user