diff options
| author | 2019-03-15 23:28:29 -0400 | |
|---|---|---|
| committer | 2019-03-15 23:58:31 -0400 | |
| commit | c892cf01fad0c1fdeb6fc4644000c026176fe05a (patch) | |
| tree | 4a4b6aac7d872c204fb4b9d4279f041d04939d15 /src/core/hle/kernel/thread.h | |
| parent | Merge pull request #2211 from lioncash/arbiter (diff) | |
| download | yuzu-c892cf01fad0c1fdeb6fc4644000c026176fe05a.tar.gz yuzu-c892cf01fad0c1fdeb6fc4644000c026176fe05a.tar.xz yuzu-c892cf01fad0c1fdeb6fc4644000c026176fe05a.zip | |
kernel/thread: Migrate WaitCurrentThread_Sleep into the Thread interface
Rather than make a global accessor for this sort of thing. We can make
it a part of the thread interface itself. This allows getting rid of a
hidden global accessor in the kernel code.
Diffstat (limited to 'src/core/hle/kernel/thread.h')
| -rw-r--r-- | src/core/hle/kernel/thread.h | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/core/hle/kernel/thread.h b/src/core/hle/kernel/thread.h index c48b21aba..d7c7a31f7 100644 --- a/src/core/hle/kernel/thread.h +++ b/src/core/hle/kernel/thread.h | |||
| @@ -383,6 +383,9 @@ public: | |||
| 383 | 383 | ||
| 384 | void SetActivity(ThreadActivity value); | 384 | void SetActivity(ThreadActivity value); |
| 385 | 385 | ||
| 386 | /// Sleeps this thread for the given amount of nanoseconds. | ||
| 387 | void Sleep(s64 nanoseconds); | ||
| 388 | |||
| 386 | private: | 389 | private: |
| 387 | explicit Thread(KernelCore& kernel); | 390 | explicit Thread(KernelCore& kernel); |
| 388 | ~Thread() override; | 391 | ~Thread() override; |
| @@ -461,11 +464,6 @@ private: | |||
| 461 | Thread* GetCurrentThread(); | 464 | Thread* GetCurrentThread(); |
| 462 | 465 | ||
| 463 | /** | 466 | /** |
| 464 | * Waits the current thread on a sleep | ||
| 465 | */ | ||
| 466 | void WaitCurrentThread_Sleep(); | ||
| 467 | |||
| 468 | /** | ||
| 469 | * Stops the current thread and removes it from the thread_list | 467 | * Stops the current thread and removes it from the thread_list |
| 470 | */ | 468 | */ |
| 471 | void ExitCurrentThread(); | 469 | void ExitCurrentThread(); |