summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/sm/controller.cpp
diff options
context:
space:
mode:
authorVolcaEM <63682805+VolcaEM@users.noreply.github.com>2020-06-29 04:01:34 +0200
committerGitHub <noreply@github.com>2020-06-29 04:01:34 +0200
commit6a0010d0c64ff3e023d8f16e543dfaf73c531179 (patch)
tree555a880d3ffce95547fedd0b2eb1a1fdfd829422 /src/core/hle/service/sm/controller.cpp
parentMerge pull request #3982 from ReinUsesLisp/membar-cts (diff)
downloadyuzu-6a0010d0c64ff3e023d8f16e543dfaf73c531179.tar
yuzu-6a0010d0c64ff3e023d8f16e543dfaf73c531179.tar.gz
yuzu-6a0010d0c64ff3e023d8f16e543dfaf73c531179.tar.bz2
yuzu-6a0010d0c64ff3e023d8f16e543dfaf73c531179.tar.lz
yuzu-6a0010d0c64ff3e023d8f16e543dfaf73c531179.tar.xz
yuzu-6a0010d0c64ff3e023d8f16e543dfaf73c531179.tar.zst
yuzu-6a0010d0c64ff3e023d8f16e543dfaf73c531179.zip
Diffstat (limited to 'src/core/hle/service/sm/controller.cpp')
-rw-r--r--src/core/hle/service/sm/controller.cpp19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/core/hle/service/sm/controller.cpp b/src/core/hle/service/sm/controller.cpp
index 9cca84b31..25ab667f3 100644
--- a/src/core/hle/service/sm/controller.cpp
+++ b/src/core/hle/service/sm/controller.cpp
@@ -12,7 +12,7 @@
namespace Service::SM {
-void Controller::ConvertSessionToDomain(Kernel::HLERequestContext& ctx) {
+void Controller::ConvertCurrentObjectToDomain(Kernel::HLERequestContext& ctx) {
ASSERT_MSG(ctx.Session()->IsSession(), "Session is already a domain");
LOG_DEBUG(Service, "called, server_session={}", ctx.Session()->GetObjectId());
ctx.Session()->ConvertToDomain();
@@ -22,7 +22,7 @@ void Controller::ConvertSessionToDomain(Kernel::HLERequestContext& ctx) {
rb.Push<u32>(1); // Converted sessions start with 1 request handler
}
-void Controller::DuplicateSession(Kernel::HLERequestContext& ctx) {
+void Controller::CloneCurrentObject(Kernel::HLERequestContext& ctx) {
// TODO(bunnei): This is just creating a new handle to the same Session. I assume this is wrong
// and that we probably want to actually make an entirely new Session, but we still need to
// verify this on hardware.
@@ -33,10 +33,10 @@ void Controller::DuplicateSession(Kernel::HLERequestContext& ctx) {
rb.PushMoveObjects(ctx.Session()->GetParent()->Client());
}
-void Controller::DuplicateSessionEx(Kernel::HLERequestContext& ctx) {
- LOG_WARNING(Service, "(STUBBED) called, using DuplicateSession");
+void Controller::CloneCurrentObjectEx(Kernel::HLERequestContext& ctx) {
+ LOG_WARNING(Service, "(STUBBED) called, using CloneCurrentObject");
- DuplicateSession(ctx);
+ CloneCurrentObject(ctx);
}
void Controller::QueryPointerBufferSize(Kernel::HLERequestContext& ctx) {
@@ -47,13 +47,14 @@ void Controller::QueryPointerBufferSize(Kernel::HLERequestContext& ctx) {
rb.Push<u16>(0x1000);
}
+// https://switchbrew.org/wiki/IPC_Marshalling
Controller::Controller() : ServiceFramework("IpcController") {
static const FunctionInfo functions[] = {
- {0x00000000, &Controller::ConvertSessionToDomain, "ConvertSessionToDomain"},
- {0x00000001, nullptr, "ConvertDomainToSession"},
- {0x00000002, &Controller::DuplicateSession, "DuplicateSession"},
+ {0x00000000, &Controller::ConvertCurrentObjectToDomain, "ConvertCurrentObjectToDomain"},
+ {0x00000001, nullptr, "CopyFromCurrentDomain"},
+ {0x00000002, &Controller::CloneCurrentObject, "CloneCurrentObject"},
{0x00000003, &Controller::QueryPointerBufferSize, "QueryPointerBufferSize"},
- {0x00000004, &Controller::DuplicateSessionEx, "DuplicateSessionEx"},
+ {0x00000004, &Controller::CloneCurrentObjectEx, "CloneCurrentObjectEx"},
};
RegisterHandlers(functions);
}