diff options
author | bunnei <bunneidev@gmail.com> | 2020-12-04 07:26:42 +0100 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2020-12-06 09:03:24 +0100 |
commit | ccce6cb3be062fc7ae162bed32202538ebc2e3d9 (patch) | |
tree | 206612bfc3718371d2355c8e3447aba288b1828f /src/core/hle/kernel/kernel.cpp | |
parent | hle: kernel: Separate KScopedSchedulerLockAndSleep from k_scheduler. (diff) | |
download | yuzu-ccce6cb3be062fc7ae162bed32202538ebc2e3d9.tar yuzu-ccce6cb3be062fc7ae162bed32202538ebc2e3d9.tar.gz yuzu-ccce6cb3be062fc7ae162bed32202538ebc2e3d9.tar.bz2 yuzu-ccce6cb3be062fc7ae162bed32202538ebc2e3d9.tar.lz yuzu-ccce6cb3be062fc7ae162bed32202538ebc2e3d9.tar.xz yuzu-ccce6cb3be062fc7ae162bed32202538ebc2e3d9.tar.zst yuzu-ccce6cb3be062fc7ae162bed32202538ebc2e3d9.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/hle/kernel/kernel.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/core/hle/kernel/kernel.cpp b/src/core/hle/kernel/kernel.cpp index b74e34c40..04cae3a43 100644 --- a/src/core/hle/kernel/kernel.cpp +++ b/src/core/hle/kernel/kernel.cpp @@ -146,7 +146,7 @@ struct KernelCore::Impl { preemption_event = Core::Timing::CreateEvent( "PreemptionCallback", [this, &kernel](std::uintptr_t, std::chrono::nanoseconds) { { - SchedulerLock lock(kernel); + KScopedSchedulerLock lock(kernel); global_scheduler_context->PreemptThreads(); } const auto time_interval = std::chrono::nanoseconds{ @@ -612,7 +612,7 @@ const Kernel::SharedMemory& KernelCore::GetTimeSharedMem() const { void KernelCore::Suspend(bool in_suspention) { const bool should_suspend = exception_exited || in_suspention; { - SchedulerLock lock(*this); + KScopedSchedulerLock lock(*this); ThreadStatus status = should_suspend ? ThreadStatus::Ready : ThreadStatus::WaitSleep; for (std::size_t i = 0; i < Core::Hardware::NUM_CPU_CORES; i++) { impl->suspend_threads[i]->SetStatus(status); |