aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/kernel/k_thread_queue.cpp
diff options
context:
space:
mode:
authorlizzie <lizzie@eden-emu.dev>2026-06-23 06:31:25 +0200
committercrueter <crueter@eden-emu.dev>2026-06-23 06:31:25 +0200
commit3aa0d462598beb2021308eee1d757d74fe33b312 (patch)
treeed425c3845ba8fa61184d97b0588cb049b518bd7 /src/core/hle/kernel/k_thread_queue.cpp
parentf8facda35fe7f17143f84bbfbdacc4cc48678946 (diff)
[video_core, hle] remove redundant parent references in system structs (#3908)
reworked a bit to remove references of parent objects and instead pass as arguments to methods to prevent useless reloads Signed-off-by: lizzie <lizzie@eden-emu.dev> Co-authored-by: maufeat <sahyno1996@gmail.com> Reviewed-on: https://git.eden-emu.dev/eden-emu/eden/pulls/3908 Reviewed-by: Maufeat <sahyno1996@gmail.com> Reviewed-by: crueter <crueter@eden-emu.dev>
Diffstat (limited to 'src/core/hle/kernel/k_thread_queue.cpp')
-rw-r--r--src/core/hle/kernel/k_thread_queue.cpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/core/hle/kernel/k_thread_queue.cpp b/src/core/hle/kernel/k_thread_queue.cpp
index 61488f4ce6..7c4bfe5a49 100644
--- a/src/core/hle/kernel/k_thread_queue.cpp
+++ b/src/core/hle/kernel/k_thread_queue.cpp
@@ -1,3 +1,6 @@
+// SPDX-FileCopyrightText: Copyright 2026 Eden Emulator Project
+// SPDX-License-Identifier: GPL-3.0-or-later
+
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later
@@ -7,17 +10,16 @@
namespace Kernel {
-void KThreadQueue::NotifyAvailable(KThread* waiting_thread, KSynchronizationObject* signaled_object,
- Result wait_result) {
+void KThreadQueue::NotifyAvailable(KernelCore& kernel, KThread* waiting_thread, KSynchronizationObject* signaled_object, Result wait_result) {
UNREACHABLE();
}
-void KThreadQueue::EndWait(KThread* waiting_thread, Result wait_result) {
+void KThreadQueue::EndWait(KernelCore& kernel, KThread* waiting_thread, Result wait_result) {
// Set the thread's wait result.
waiting_thread->SetWaitResult(wait_result);
// Set the thread as runnable.
- waiting_thread->SetState(ThreadState::Runnable);
+ waiting_thread->SetState(kernel, ThreadState::Runnable);
// Clear the thread's wait queue.
waiting_thread->ClearWaitQueue();
@@ -28,12 +30,12 @@ void KThreadQueue::EndWait(KThread* waiting_thread, Result wait_result) {
}
}
-void KThreadQueue::CancelWait(KThread* waiting_thread, Result wait_result, bool cancel_timer_task) {
+void KThreadQueue::CancelWait(KernelCore& kernel, KThread* waiting_thread, Result wait_result, bool cancel_timer_task) {
// Set the thread's wait result.
waiting_thread->SetWaitResult(wait_result);
// Set the thread as runnable.
- waiting_thread->SetState(ThreadState::Runnable);
+ waiting_thread->SetState(kernel, ThreadState::Runnable);
// Clear the thread's wait queue.
waiting_thread->ClearWaitQueue();
@@ -44,7 +46,7 @@ void KThreadQueue::CancelWait(KThread* waiting_thread, Result wait_result, bool
}
}
-void KThreadQueueWithoutEndWait::EndWait(KThread* waiting_thread, Result wait_result) {
+void KThreadQueueWithoutEndWait::EndWait(KernelCore& kernel, KThread* waiting_thread, Result wait_result) {
UNREACHABLE();
}