|
|
|
@ -17,7 +17,6 @@ TestEnvironment::TestEnvironment(bool mutable_memory_)
|
|
|
|
|
: mutable_memory(mutable_memory_),
|
|
|
|
|
test_memory(std::make_shared<TestMemory>(this)), kernel{Core::System::GetInstance()} {
|
|
|
|
|
auto process = Kernel::Process::Create(Core::System::GetInstance(), "");
|
|
|
|
|
kernel.MakeCurrentProcess(process.get());
|
|
|
|
|
page_table = &process->VMManager().page_table;
|
|
|
|
|
|
|
|
|
|
std::fill(page_table->pointers.begin(), page_table->pointers.end(), nullptr);
|
|
|
|
@ -28,7 +27,7 @@ TestEnvironment::TestEnvironment(bool mutable_memory_)
|
|
|
|
|
Memory::MapIoRegion(*page_table, 0x00000000, 0x80000000, test_memory);
|
|
|
|
|
Memory::MapIoRegion(*page_table, 0x80000000, 0x80000000, test_memory);
|
|
|
|
|
|
|
|
|
|
Memory::SetCurrentPageTable(page_table);
|
|
|
|
|
kernel.MakeCurrentProcess(process.get());
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
TestEnvironment::~TestEnvironment() {
|
|
|
|
|