summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar bunnei2014-05-17 23:37:25 -0400
committerGravatar bunnei2014-05-17 23:37:25 -0400
commit6a6c7eeccbf2e9a766ad6b942f25b3ef6e008944 (patch)
treefe4da52d576ddd7aec12e250e14e1d77448035cc /src
parentignore thumbemu 0xDEADCODE debugging catch on MCR (diff)
downloadyuzu-6a6c7eeccbf2e9a766ad6b942f25b3ef6e008944.tar.gz
yuzu-6a6c7eeccbf2e9a766ad6b942f25b3ef6e008944.tar.xz
yuzu-6a6c7eeccbf2e9a766ad6b942f25b3ef6e008944.zip
added stubbed function for WaitSynchronizationN
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/function_wrappers.h7
-rw-r--r--src/core/hle/syscall.cpp16
2 files changed, 19 insertions, 4 deletions
diff --git a/src/core/hle/function_wrappers.h b/src/core/hle/function_wrappers.h
index 61790e5a3..24cc74fc6 100644
--- a/src/core/hle/function_wrappers.h
+++ b/src/core/hle/function_wrappers.h
@@ -750,6 +750,11 @@ template<int func(void*, u32, u32, u32, u32, u32)> void WrapI_VUUUUU(){
750} 750}
751 751
752template<int func(u32, s64)> void WrapI_US64() { 752template<int func(u32, s64)> void WrapI_US64() {
753 int retval = func(PARAM(0), PARAM64(2)); 753 int retval = func(PARAM(0), PARAM64(1));
754 RETURN(retval);
755}
756
757template<int func(void*, void*, u32, u32, s64)> void WrapI_VVUUS64() {
758 int retval = func(Memory::GetPointer(PARAM(0)), Memory::GetPointer(PARAM(1)), PARAM(2), PARAM(3), PARAM(4));
754 RETURN(retval); 759 RETURN(retval);
755} 760}
diff --git a/src/core/hle/syscall.cpp b/src/core/hle/syscall.cpp
index 0c78b19fb..728679378 100644
--- a/src/core/hle/syscall.cpp
+++ b/src/core/hle/syscall.cpp
@@ -104,10 +104,20 @@ Result CloseHandle(Handle handle) {
104} 104}
105 105
106/// Wait for a handle to synchronize, timeout after the specified nanoseconds 106/// Wait for a handle to synchronize, timeout after the specified nanoseconds
107Result WaitSynchronization1(Handle handle, s64 nanoseconds) { 107Result WaitSynchronization1(Handle handle, s64 nano_seconds) {
108 // ImplementMe 108 // ImplementMe
109 DEBUG_LOG(SVC, "(UNIMPLEMENTED) WaitSynchronization1 called handle=0x%08X, nanoseconds=%d", 109 DEBUG_LOG(SVC, "(UNIMPLEMENTED) WaitSynchronization1 called handle=0x%08X, nanoseconds=%d",
110 handle, nanoseconds); 110 handle, nano_seconds);
111 return 0;
112}
113
114/// Wait for the given handles to synchronize, timeout after the specified nanoseconds
115Result WaitSynchronizationN(void* _out, void* _handles, u32 handle_count, u32 wait_all, s64 nano_seconds) {
116 s32* out = (s32*)_out;
117 Handle* handles = (Handle*)_handles;
118 // ImplementMe
119 DEBUG_LOG(SVC, "(UNIMPLEMENTED) WaitSynchronizationN called handle_count=%d, wait_all=%d, nanoseconds=%d",
120 handle_count, wait_all, nano_seconds);
111 return 0; 121 return 0;
112} 122}
113 123
@@ -226,7 +236,7 @@ const HLE::FunctionDef Syscall_Table[] = {
226 {0x22, NULL, "ArbitrateAddress"}, 236 {0x22, NULL, "ArbitrateAddress"},
227 {0x23, WrapI_U<CloseHandle>, "CloseHandle"}, 237 {0x23, WrapI_U<CloseHandle>, "CloseHandle"},
228 {0x24, WrapI_US64<WaitSynchronization1>, "WaitSynchronization1"}, 238 {0x24, WrapI_US64<WaitSynchronization1>, "WaitSynchronization1"},
229 {0x25, NULL, "WaitSynchronizationN"}, 239 {0x25, WrapI_VVUUS64<WaitSynchronizationN>, "WaitSynchronizationN"},
230 {0x26, NULL, "SignalAndWait"}, 240 {0x26, NULL, "SignalAndWait"},
231 {0x27, NULL, "DuplicateHandle"}, 241 {0x27, NULL, "DuplicateHandle"},
232 {0x28, NULL, "GetSystemTick"}, 242 {0x28, NULL, "GetSystemTick"},