diff options
author | Zach Hilman <zachhilman@gmail.com> | 2018-11-27 00:34:07 +0100 |
---|---|---|
committer | Zach Hilman <zachhilman@gmail.com> | 2018-11-29 14:45:41 +0100 |
commit | ff610103b58b3e0dd39fafb539a1cc0bc0fae577 (patch) | |
tree | cbd54b09f9270f6f1d92a2f45a5ccdb307569093 /src/core/hle/kernel | |
parent | hle_ipc: Use event pair for SleepClientThread (diff) | |
download | yuzu-ff610103b58b3e0dd39fafb539a1cc0bc0fae577.tar yuzu-ff610103b58b3e0dd39fafb539a1cc0bc0fae577.tar.gz yuzu-ff610103b58b3e0dd39fafb539a1cc0bc0fae577.tar.bz2 yuzu-ff610103b58b3e0dd39fafb539a1cc0bc0fae577.tar.lz yuzu-ff610103b58b3e0dd39fafb539a1cc0bc0fae577.tar.xz yuzu-ff610103b58b3e0dd39fafb539a1cc0bc0fae577.tar.zst yuzu-ff610103b58b3e0dd39fafb539a1cc0bc0fae577.zip |
Diffstat (limited to 'src/core/hle/kernel')
-rw-r--r-- | src/core/hle/kernel/svc.cpp | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/core/hle/kernel/svc.cpp b/src/core/hle/kernel/svc.cpp index 5e9660a48..85a9c50fb 100644 --- a/src/core/hle/kernel/svc.cpp +++ b/src/core/hle/kernel/svc.cpp @@ -20,17 +20,18 @@ #include "core/hle/kernel/address_arbiter.h" #include "core/hle/kernel/client_port.h" #include "core/hle/kernel/client_session.h" -#include "core/hle/kernel/event.h" #include "core/hle/kernel/handle_table.h" #include "core/hle/kernel/kernel.h" #include "core/hle/kernel/mutex.h" #include "core/hle/kernel/process.h" +#include "core/hle/kernel/readable_event.h" #include "core/hle/kernel/resource_limit.h" #include "core/hle/kernel/scheduler.h" #include "core/hle/kernel/shared_memory.h" #include "core/hle/kernel/svc.h" #include "core/hle/kernel/svc_wrap.h" #include "core/hle/kernel/thread.h" +#include "core/hle/kernel/writable_event.h" #include "core/hle/lock.h" #include "core/hle/result.h" #include "core/hle/service/service.h" @@ -1361,11 +1362,11 @@ static ResultCode ResetSignal(Handle handle) { LOG_DEBUG(Kernel_SVC, "called handle 0x{:08X}", handle); const auto& handle_table = Core::CurrentProcess()->GetHandleTable(); - auto event = handle_table.Get<Event>(handle); + auto event = handle_table.Get<ReadableEvent>(handle); ASSERT(event != nullptr); - event->Clear(); + event->PromoteToWritable()->Clear(); return RESULT_SUCCESS; } @@ -1524,13 +1525,13 @@ static ResultCode ClearEvent(Handle handle) { LOG_TRACE(Kernel_SVC, "called, event=0x{:08X}", handle); const auto& handle_table = Core::CurrentProcess()->GetHandleTable(); - SharedPtr<Event> evt = handle_table.Get<Event>(handle); + SharedPtr<ReadableEvent> evt = handle_table.Get<ReadableEvent>(handle); if (evt == nullptr) { LOG_ERROR(Kernel_SVC, "Event handle does not exist, handle=0x{:08X}", handle); return ERR_INVALID_HANDLE; } - evt->Clear(); + evt->PromoteToWritable()->Clear(); return RESULT_SUCCESS; } |