2
1
Fork 0
mirror of https://github.com/yuzu-emu/yuzu.git synced 2024-07-04 23:31:19 +01:00

controller: Implement DuplicateSession.

This commit is contained in:
bunnei 2017-12-29 00:39:34 -05:00
parent dcdaac8a0b
commit 30e98fae3f
2 changed files with 11 additions and 9 deletions

View file

@ -21,19 +21,20 @@ void Controller::ConvertSessionToDomain(Kernel::HLERequestContext& ctx) {
LOG_DEBUG(Service, "called, domain=%d", domain->GetObjectId()); LOG_DEBUG(Service, "called, domain=%d", domain->GetObjectId());
} }
/** void Controller::DuplicateSession(Kernel::HLERequestContext& ctx) {
* Controller::QueryPointerBufferSize service function IPC::RequestBuilder rb{ctx, 1, 0, 1};
* Inputs: rb.Push(RESULT_SUCCESS);
* 0: 0x00000003 rb.PushObjects(ctx.ServerSession());
* Outputs:
* 0: ResultCode LOG_DEBUG(Service, "called");
* 2: Size of memory }
*/
void Controller::QueryPointerBufferSize(Kernel::HLERequestContext& ctx) { void Controller::QueryPointerBufferSize(Kernel::HLERequestContext& ctx) {
IPC::RequestBuilder rb{ctx, 3}; IPC::RequestBuilder rb{ctx, 3};
rb.Push(RESULT_SUCCESS); rb.Push(RESULT_SUCCESS);
rb.Skip(1, true); rb.Skip(1, true);
rb.Push<u32>(0x500); rb.Push<u32>(0x500);
LOG_WARNING(Service, "(STUBBED) called"); LOG_WARNING(Service, "(STUBBED) called");
} }
@ -41,7 +42,7 @@ Controller::Controller() : ServiceFramework("IpcController") {
static const FunctionInfo functions[] = { static const FunctionInfo functions[] = {
{0x00000000, &Controller::ConvertSessionToDomain, "ConvertSessionToDomain"}, {0x00000000, &Controller::ConvertSessionToDomain, "ConvertSessionToDomain"},
{0x00000001, nullptr, "ConvertDomainToSession"}, {0x00000001, nullptr, "ConvertDomainToSession"},
{0x00000002, nullptr, "DuplicateSession"}, {0x00000002, &Controller::DuplicateSession, "DuplicateSession"},
{0x00000003, &Controller::QueryPointerBufferSize, "QueryPointerBufferSize"}, {0x00000003, &Controller::QueryPointerBufferSize, "QueryPointerBufferSize"},
{0x00000004, nullptr, "DuplicateSessionEx"}, {0x00000004, nullptr, "DuplicateSessionEx"},
}; };

View file

@ -16,6 +16,7 @@ public:
private: private:
void ConvertSessionToDomain(Kernel::HLERequestContext& ctx); void ConvertSessionToDomain(Kernel::HLERequestContext& ctx);
void DuplicateSession(Kernel::HLERequestContext& ctx);
void QueryPointerBufferSize(Kernel::HLERequestContext& ctx); void QueryPointerBufferSize(Kernel::HLERequestContext& ctx);
}; };