summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/core/hle/kernel/kernel.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/core/hle/kernel/kernel.cpp b/src/core/hle/kernel/kernel.cpp
index e994e8bed..557e63ea0 100644
--- a/src/core/hle/kernel/kernel.cpp
+++ b/src/core/hle/kernel/kernel.cpp
@@ -269,9 +269,7 @@ struct KernelCore::Impl {
269 return schedulers[thread_id]->GetCurrentThread(); 269 return schedulers[thread_id]->GetCurrentThread();
270 } 270 }
271 271
272 void InitializeMemoryLayout() { 272 void DeriveInitialMemoryLayout(KMemoryLayout& memory_layout) {
273 KMemoryLayout memory_layout;
274
275 // Insert the root region for the virtual memory tree, from which all other regions will 273 // Insert the root region for the virtual memory tree, from which all other regions will
276 // derive. 274 // derive.
277 memory_layout.GetVirtualMemoryRegionTree().InsertDirectly( 275 memory_layout.GetVirtualMemoryRegionTree().InsertDirectly(
@@ -531,6 +529,12 @@ struct KernelCore::Impl {
531 // Cache all linear regions in their own trees for faster access, later. 529 // Cache all linear regions in their own trees for faster access, later.
532 memory_layout.InitializeLinearMemoryRegionTrees(aligned_linear_phys_start, 530 memory_layout.InitializeLinearMemoryRegionTrees(aligned_linear_phys_start,
533 linear_region_start); 531 linear_region_start);
532 }
533
534 void InitializeMemoryLayout() {
535 // Derive the initial memory layout from the emulated board
536 KMemoryLayout memory_layout;
537 DeriveInitialMemoryLayout(memory_layout);
534 538
535 const auto system_pool = memory_layout.GetKernelSystemPoolRegionPhysicalExtents(); 539 const auto system_pool = memory_layout.GetKernelSystemPoolRegionPhysicalExtents();
536 const auto applet_pool = memory_layout.GetKernelAppletPoolRegionPhysicalExtents(); 540 const auto applet_pool = memory_layout.GetKernelAppletPoolRegionPhysicalExtents();