aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/service/sockets/bsd_u.cpp
diff options
context:
space:
mode:
authormailwl <mailwl@gmail.com>2018-03-25 12:41:00 +0300
committermailwl <mailwl@gmail.com>2018-03-25 12:41:00 +0300
commit692639e9b786b48303d0735222b5eba99d016d21 (patch)
tree75febb12f0247dc8f855bd1be845722141005287 /src/core/hle/service/sockets/bsd_u.cpp
parent46945b5c962e680d8fe963bbff9663f44c2a3ab2 (diff)
Service/sockets: add bsd:s, nsd:a, nsd:u services
Diffstat (limited to 'src/core/hle/service/sockets/bsd_u.cpp')
-rw-r--r--src/core/hle/service/sockets/bsd_u.cpp88
1 files changed, 0 insertions, 88 deletions
diff --git a/src/core/hle/service/sockets/bsd_u.cpp b/src/core/hle/service/sockets/bsd_u.cpp
deleted file mode 100644
index 2ca1000ca..000000000
--- a/src/core/hle/service/sockets/bsd_u.cpp
+++ /dev/null
@@ -1,88 +0,0 @@
-// Copyright 2018 yuzu emulator team
-// Licensed under GPLv2 or any later version
-// Refer to the license.txt file included.
-
-#include "core/hle/ipc_helpers.h"
-#include "core/hle/service/sockets/bsd_u.h"
-
-namespace Service {
-namespace Sockets {
-
-void BSD_U::RegisterClient(Kernel::HLERequestContext& ctx) {
- LOG_WARNING(Service, "(STUBBED) called");
-
- IPC::ResponseBuilder rb{ctx, 3};
-
- rb.Push(RESULT_SUCCESS);
- rb.Push<u32>(0); // bsd errno
-}
-
-void BSD_U::StartMonitoring(Kernel::HLERequestContext& ctx) {
- LOG_WARNING(Service, "(STUBBED) called");
-
- IPC::ResponseBuilder rb{ctx, 3};
-
- rb.Push(RESULT_SUCCESS);
- rb.Push<u32>(0); // bsd errno
-}
-
-void BSD_U::Socket(Kernel::HLERequestContext& ctx) {
- IPC::RequestParser rp{ctx};
-
- u32 domain = rp.Pop<u32>();
- u32 type = rp.Pop<u32>();
- u32 protocol = rp.Pop<u32>();
-
- LOG_WARNING(Service, "(STUBBED) called domain=%u type=%u protocol=%u", domain, type, protocol);
-
- u32 fd = next_fd++;
-
- IPC::ResponseBuilder rb{ctx, 4};
-
- rb.Push(RESULT_SUCCESS);
- rb.Push<u32>(fd);
- rb.Push<u32>(0); // bsd errno
-}
-
-void BSD_U::Connect(Kernel::HLERequestContext& ctx) {
- LOG_WARNING(Service, "(STUBBED) called");
-
- IPC::ResponseBuilder rb{ctx, 4};
-
- rb.Push(RESULT_SUCCESS);
- rb.Push<u32>(0); // ret
- rb.Push<u32>(0); // bsd errno
-}
-
-void BSD_U::SendTo(Kernel::HLERequestContext& ctx) {
- LOG_WARNING(Service, "(STUBBED) called");
-
- IPC::ResponseBuilder rb{ctx, 4};
-
- rb.Push(RESULT_SUCCESS);
- rb.Push<u32>(0); // ret
- rb.Push<u32>(0); // bsd errno
-}
-
-void BSD_U::Close(Kernel::HLERequestContext& ctx) {
- LOG_WARNING(Service, "(STUBBED) called");
-
- IPC::ResponseBuilder rb{ctx, 4};
-
- rb.Push(RESULT_SUCCESS);
- rb.Push<u32>(0); // ret
- rb.Push<u32>(0); // bsd errno
-}
-
-BSD_U::BSD_U() : ServiceFramework("bsd:u") {
- static const FunctionInfo functions[] = {{0, &BSD_U::RegisterClient, "RegisterClient"},
- {1, &BSD_U::StartMonitoring, "StartMonitoring"},
- {2, &BSD_U::Socket, "Socket"},
- {11, &BSD_U::SendTo, "SendTo"},
- {14, &BSD_U::Connect, "Connect"},
- {26, &BSD_U::Close, "Close"}};
- RegisterHandlers(functions);
-}
-
-} // namespace Sockets
-} // namespace Service