summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service
diff options
context:
space:
mode:
authorSubv <subv2112@gmail.com>2015-06-25 19:55:27 +0200
committerSubv <subv2112@gmail.com>2015-06-25 19:55:27 +0200
commitbd336cfdce60ee18a1d8f344afbeed922a8a588c (patch)
tree71f50475a055752fbb391281a25c09ec43cf6dc8 /src/core/hle/service
parentMerge pull request #877 from yuriks/ipc-headers (diff)
downloadyuzu-bd336cfdce60ee18a1d8f344afbeed922a8a588c.tar
yuzu-bd336cfdce60ee18a1d8f344afbeed922a8a588c.tar.gz
yuzu-bd336cfdce60ee18a1d8f344afbeed922a8a588c.tar.bz2
yuzu-bd336cfdce60ee18a1d8f344afbeed922a8a588c.tar.lz
yuzu-bd336cfdce60ee18a1d8f344afbeed922a8a588c.tar.xz
yuzu-bd336cfdce60ee18a1d8f344afbeed922a8a588c.tar.zst
yuzu-bd336cfdce60ee18a1d8f344afbeed922a8a588c.zip
Diffstat (limited to 'src/core/hle/service')
-rw-r--r--src/core/hle/service/soc_u.cpp18
1 files changed, 13 insertions, 5 deletions
diff --git a/src/core/hle/service/soc_u.cpp b/src/core/hle/service/soc_u.cpp
index 1e0f5df9b..1bd420552 100644
--- a/src/core/hle/service/soc_u.cpp
+++ b/src/core/hle/service/soc_u.cpp
@@ -328,6 +328,7 @@ static void Socket(Service::Interface* self) {
if ((s32)socket_handle == SOCKET_ERROR_VALUE)
result = TranslateError(GET_ERRNO);
+ cmd_buffer[0] = IPC::MakeHeader(2, 2, 0);
cmd_buffer[1] = result;
cmd_buffer[2] = socket_handle;
}
@@ -351,8 +352,9 @@ static void Bind(Service::Interface* self) {
if (res != 0)
result = TranslateError(GET_ERRNO);
- cmd_buffer[2] = res;
+ cmd_buffer[0] = IPC::MakeHeader(5, 2, 0);
cmd_buffer[1] = result;
+ cmd_buffer[2] = res;
}
static void Fcntl(Service::Interface* self) {
@@ -434,8 +436,9 @@ static void Listen(Service::Interface* self) {
if (ret != 0)
result = TranslateError(GET_ERRNO);
- cmd_buffer[2] = ret;
+ cmd_buffer[0] = IPC::MakeHeader(3, 2, 0);
cmd_buffer[1] = result;
+ cmd_buffer[2] = ret;
}
static void Accept(Service::Interface* self) {
@@ -460,8 +463,10 @@ static void Accept(Service::Interface* self) {
Memory::WriteBlock(cmd_buffer[0x104 >> 2], (const u8*)&ctr_addr, max_addr_len);
}
- cmd_buffer[2] = ret;
+ cmd_buffer[0] = IPC::MakeHeader(4, 2, 2);
cmd_buffer[1] = result;
+ cmd_buffer[2] = ret;
+ cmd_buffer[3] = IPC::StaticBufferDesc(static_cast<u32>(max_addr_len), 0);
}
static void GetHostId(Service::Interface* self) {
@@ -669,8 +674,10 @@ static void Connect(Service::Interface* self) {
int result = 0;
if (ret != 0)
result = TranslateError(GET_ERRNO);
- cmd_buffer[2] = ret;
+
+ cmd_buffer[0] = IPC::MakeHeader(6, 2, 0);
cmd_buffer[1] = result;
+ cmd_buffer[2] = ret;
}
static void InitializeSockets(Service::Interface* self) {
@@ -681,7 +688,8 @@ static void InitializeSockets(Service::Interface* self) {
#endif
u32* cmd_buffer = Kernel::GetCommandBuffer();
- cmd_buffer[1] = 0;
+ cmd_buffer[0] = IPC::MakeHeader(1, 1, 0);
+ cmd_buffer[1] = RESULT_SUCCESS.raw;
}
static void ShutdownSockets(Service::Interface* self) {