summaryrefslogtreecommitdiff
path: root/src/core/hle/kernel/timer.cpp
diff options
context:
space:
mode:
authorGravatar Subv2017-01-01 16:53:22 -0500
committerGravatar Subv2017-01-04 15:58:45 -0500
commite6a7723f2f4b62279cd4f6d4b48eb02a9b60ffb6 (patch)
treeb56862bb64fcf57727149de90318671ffd8afe4d /src/core/hle/kernel/timer.cpp
parentKernel/Synch: Do not attempt a reschedule on every syscall. (diff)
downloadyuzu-e6a7723f2f4b62279cd4f6d4b48eb02a9b60ffb6.tar.gz
yuzu-e6a7723f2f4b62279cd4f6d4b48eb02a9b60ffb6.tar.xz
yuzu-e6a7723f2f4b62279cd4f6d4b48eb02a9b60ffb6.zip
Kernel: Object ShouldWait and Acquire calls now take a thread as a parameter.
This will be useful when implementing mutex priority inheritance.
Diffstat (limited to 'src/core/hle/kernel/timer.cpp')
-rw-r--r--src/core/hle/kernel/timer.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/hle/kernel/timer.cpp b/src/core/hle/kernel/timer.cpp
index b50cf520d..8f2bc4c7f 100644
--- a/src/core/hle/kernel/timer.cpp
+++ b/src/core/hle/kernel/timer.cpp
@@ -39,12 +39,12 @@ SharedPtr<Timer> Timer::Create(ResetType reset_type, std::string name) {
39 return timer; 39 return timer;
40} 40}
41 41
42bool Timer::ShouldWait() { 42bool Timer::ShouldWait(Thread* thread) const {
43 return !signaled; 43 return !signaled;
44} 44}
45 45
46void Timer::Acquire() { 46void Timer::Acquire(Thread* thread) {
47 ASSERT_MSG(!ShouldWait(), "object unavailable!"); 47 ASSERT_MSG(!ShouldWait(thread), "object unavailable!");
48 48
49 if (reset_type == ResetType::OneShot) 49 if (reset_type == ResetType::OneShot)
50 signaled = false; 50 signaled = false;