summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/core/hle/kernel/kernel.cpp8
-rw-r--r--src/core/hle/kernel/physical_core.cpp5
-rw-r--r--src/core/hle/kernel/physical_core.h5
3 files changed, 7 insertions, 11 deletions
diff --git a/src/core/hle/kernel/kernel.cpp b/src/core/hle/kernel/kernel.cpp
index 0cf3c8f70..edd4c4259 100644
--- a/src/core/hle/kernel/kernel.cpp
+++ b/src/core/hle/kernel/kernel.cpp
@@ -101,7 +101,7 @@ struct KernelCore::Impl {
101 void Initialize(KernelCore& kernel) { 101 void Initialize(KernelCore& kernel) {
102 Shutdown(); 102 Shutdown();
103 103
104 InitializePhysicalCores(kernel); 104 InitializePhysicalCores();
105 InitializeSystemResourceLimit(kernel); 105 InitializeSystemResourceLimit(kernel);
106 InitializeThreads(); 106 InitializeThreads();
107 InitializePreemption(); 107 InitializePreemption();
@@ -131,14 +131,14 @@ struct KernelCore::Impl {
131 } 131 }
132 cores.clear(); 132 cores.clear();
133 133
134 exclusive_monitor.reset(nullptr); 134 exclusive_monitor.reset();
135 } 135 }
136 136
137 void InitializePhysicalCores(KernelCore& kernel) { 137 void InitializePhysicalCores() {
138 exclusive_monitor = 138 exclusive_monitor =
139 Core::MakeExclusiveMonitor(system.Memory(), global_scheduler.CpuCoresCount()); 139 Core::MakeExclusiveMonitor(system.Memory(), global_scheduler.CpuCoresCount());
140 for (std::size_t i = 0; i < global_scheduler.CpuCoresCount(); i++) { 140 for (std::size_t i = 0; i < global_scheduler.CpuCoresCount(); i++) {
141 cores.emplace_back(system, kernel, i, *exclusive_monitor); 141 cores.emplace_back(system, i, *exclusive_monitor);
142 } 142 }
143 } 143 }
144 144
diff --git a/src/core/hle/kernel/physical_core.cpp b/src/core/hle/kernel/physical_core.cpp
index 896a1a87a..e96d063fd 100644
--- a/src/core/hle/kernel/physical_core.cpp
+++ b/src/core/hle/kernel/physical_core.cpp
@@ -10,16 +10,15 @@
10#include "core/arm/exclusive_monitor.h" 10#include "core/arm/exclusive_monitor.h"
11#include "core/arm/unicorn/arm_unicorn.h" 11#include "core/arm/unicorn/arm_unicorn.h"
12#include "core/core.h" 12#include "core/core.h"
13#include "core/hle/kernel/kernel.h"
14#include "core/hle/kernel/physical_core.h" 13#include "core/hle/kernel/physical_core.h"
15#include "core/hle/kernel/scheduler.h" 14#include "core/hle/kernel/scheduler.h"
16#include "core/hle/kernel/thread.h" 15#include "core/hle/kernel/thread.h"
17 16
18namespace Kernel { 17namespace Kernel {
19 18
20PhysicalCore::PhysicalCore(Core::System& system, KernelCore& kernel, std::size_t id, 19PhysicalCore::PhysicalCore(Core::System& system, std::size_t id,
21 Core::ExclusiveMonitor& exclusive_monitor) 20 Core::ExclusiveMonitor& exclusive_monitor)
22 : core_index{id}, kernel{kernel} { 21 : core_index{id} {
23#ifdef ARCHITECTURE_x86_64 22#ifdef ARCHITECTURE_x86_64
24 arm_interface = std::make_shared<Core::ARM_Dynarmic>(system, exclusive_monitor, core_index); 23 arm_interface = std::make_shared<Core::ARM_Dynarmic>(system, exclusive_monitor, core_index);
25#else 24#else
diff --git a/src/core/hle/kernel/physical_core.h b/src/core/hle/kernel/physical_core.h
index fbef0801f..7dca97d1b 100644
--- a/src/core/hle/kernel/physical_core.h
+++ b/src/core/hle/kernel/physical_core.h
@@ -21,9 +21,7 @@ namespace Kernel {
21 21
22class PhysicalCore { 22class PhysicalCore {
23public: 23public:
24 PhysicalCore(Core::System& system, KernelCore& kernel, std::size_t id, 24 PhysicalCore(Core::System& system, std::size_t id, Core::ExclusiveMonitor& exclusive_monitor);
25 Core::ExclusiveMonitor& exclusive_monitor);
26
27 ~PhysicalCore(); 25 ~PhysicalCore();
28 26
29 /// Execute current jit state 27 /// Execute current jit state
@@ -66,7 +64,6 @@ public:
66 64
67private: 65private:
68 std::size_t core_index; 66 std::size_t core_index;
69 KernelCore& kernel;
70 std::shared_ptr<Core::ARM_Interface> arm_interface; 67 std::shared_ptr<Core::ARM_Interface> arm_interface;
71 std::shared_ptr<Kernel::Scheduler> scheduler; 68 std::shared_ptr<Kernel::Scheduler> scheduler;
72}; 69};