diff options
| author | 2018-05-19 16:56:33 -0500 | |
|---|---|---|
| committer | 2018-05-19 16:56:33 -0500 | |
| commit | fab3dd98fec042e9c6a7ccfbd549ea2d6c41cfae (patch) | |
| tree | ba6d1b5393edb16be0666d6eee02bac23ca4c050 /src/core/hle/kernel | |
| parent | Merge pull request #436 from bunnei/multi-core (diff) | |
| download | yuzu-fab3dd98fec042e9c6a7ccfbd549ea2d6c41cfae.tar.gz yuzu-fab3dd98fec042e9c6a7ccfbd549ea2d6c41cfae.tar.xz yuzu-fab3dd98fec042e9c6a7ccfbd549ea2d6c41cfae.zip | |
SVC: Removed unused WaitSynchronization1 function
Diffstat (limited to 'src/core/hle/kernel')
| -rw-r--r-- | src/core/hle/kernel/svc.cpp | 30 |
1 files changed, 0 insertions, 30 deletions
diff --git a/src/core/hle/kernel/svc.cpp b/src/core/hle/kernel/svc.cpp index 1ae530c90..1eb1b8fbf 100644 --- a/src/core/hle/kernel/svc.cpp +++ b/src/core/hle/kernel/svc.cpp | |||
| @@ -145,36 +145,6 @@ static bool DefaultThreadWakeupCallback(ThreadWakeupReason reason, SharedPtr<Thr | |||
| 145 | return true; | 145 | return true; |
| 146 | }; | 146 | }; |
| 147 | 147 | ||
| 148 | /// Wait for a kernel object to synchronize, timeout after the specified nanoseconds | ||
| 149 | static ResultCode WaitSynchronization1( | ||
| 150 | SharedPtr<WaitObject> object, Thread* thread, s64 nano_seconds = -1, | ||
| 151 | std::function<Thread::WakeupCallback> wakeup_callback = DefaultThreadWakeupCallback) { | ||
| 152 | |||
| 153 | if (!object) { | ||
| 154 | return ERR_INVALID_HANDLE; | ||
| 155 | } | ||
| 156 | |||
| 157 | if (object->ShouldWait(thread)) { | ||
| 158 | if (nano_seconds == 0) { | ||
| 159 | return RESULT_TIMEOUT; | ||
| 160 | } | ||
| 161 | |||
| 162 | thread->wait_objects = {object}; | ||
| 163 | object->AddWaitingThread(thread); | ||
| 164 | thread->status = THREADSTATUS_WAIT_SYNCH_ANY; | ||
| 165 | |||
| 166 | // Create an event to wake the thread up after the specified nanosecond delay has passed | ||
| 167 | thread->WakeAfterDelay(nano_seconds); | ||
| 168 | thread->wakeup_callback = wakeup_callback; | ||
| 169 | |||
| 170 | Core::System::GetInstance().PrepareReschedule(); | ||
| 171 | } else { | ||
| 172 | object->Acquire(thread); | ||
| 173 | } | ||
| 174 | |||
| 175 | return RESULT_SUCCESS; | ||
| 176 | } | ||
| 177 | |||
| 178 | /// Wait for the given handles to synchronize, timeout after the specified nanoseconds | 148 | /// Wait for the given handles to synchronize, timeout after the specified nanoseconds |
| 179 | static ResultCode WaitSynchronization(Handle* index, VAddr handles_address, u64 handle_count, | 149 | static ResultCode WaitSynchronization(Handle* index, VAddr handles_address, u64 handle_count, |
| 180 | s64 nano_seconds) { | 150 | s64 nano_seconds) { |