mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-04-10 05:28:56 +02:00
[hle/sm] implement sm:AtmosphereHasService
Signed-off-by: lizzie <lizzie@eden-emu.dev>
This commit is contained in:
parent
5322bce4b8
commit
5352be43c5
1 changed files with 33 additions and 2 deletions
|
|
@ -250,15 +250,37 @@ void SM::UnregisterService(HLERequestContext& ctx) {
|
|||
rb.Push(service_manager.UnregisterService(name));
|
||||
}
|
||||
|
||||
void SM::AtmosphereHasService(HLERequestContext& ctx) {
|
||||
IPC::RequestParser rp{ctx};
|
||||
std::string name(PopServiceName(rp));
|
||||
LOG_WARNING(Service_SM, "(stubbed) called with name={}", name);
|
||||
IPC::ResponseBuilder rb{ctx, 3};
|
||||
Kernel::KClientPort* out_client_port = nullptr;
|
||||
rb.Push(ResultSuccess);
|
||||
rb.Push<bool>(service_manager.GetServicePort(&out_client_port, name) == ResultSuccess);
|
||||
}
|
||||
|
||||
SM::SM(ServiceManager& service_manager_, Core::System& system_)
|
||||
: ServiceFramework{system_, "sm:", 4},
|
||||
service_manager{service_manager_}, kernel{system_.Kernel()} {
|
||||
: ServiceFramework{system_, "sm:", 4}
|
||||
, service_manager{service_manager_}
|
||||
, kernel{system_.Kernel()}
|
||||
{
|
||||
RegisterHandlers({
|
||||
{0, &SM::Initialize, "Initialize"},
|
||||
{1, &SM::GetServiceCmif, "GetService"},
|
||||
{2, &SM::RegisterServiceCmif, "RegisterService"},
|
||||
{3, &SM::UnregisterService, "UnregisterService"},
|
||||
{4, nullptr, "DetachClient"},
|
||||
// TODO: are these non-TIPC as well?
|
||||
{65000, nullptr, "AtmosphereInstallMitm"},
|
||||
{65001, nullptr, "AtmosphereUninstallMitm"},
|
||||
{65002, nullptr, "Deprecated_AtmosphereAssociatePidTidForMitm"},
|
||||
{65003, nullptr, "AtmosphereAcknowledgeMitmSession"},
|
||||
{65004, nullptr, "AtmosphereHasMitm"},
|
||||
{65005, nullptr, "AtmosphereWaitMitm"},
|
||||
{65006, nullptr, "AtmosphereDeclareFutureMitm"},
|
||||
{65100, &SM::AtmosphereHasService, "AtmosphereHasService"},
|
||||
{65101, nullptr, "AtmosphereWaitService"},
|
||||
});
|
||||
RegisterHandlersTipc({
|
||||
{0, &SM::Initialize, "Initialize"},
|
||||
|
|
@ -266,6 +288,15 @@ SM::SM(ServiceManager& service_manager_, Core::System& system_)
|
|||
{2, &SM::RegisterServiceTipc, "RegisterService"},
|
||||
{3, &SM::UnregisterService, "UnregisterService"},
|
||||
{4, nullptr, "DetachClient"},
|
||||
{65000, nullptr, "AtmosphereInstallMitm"},
|
||||
{65001, nullptr, "AtmosphereUninstallMitm"},
|
||||
{65002, nullptr, "Deprecated_AtmosphereAssociatePidTidForMitm"},
|
||||
{65003, nullptr, "AtmosphereAcknowledgeMitmSession"},
|
||||
{65004, nullptr, "AtmosphereHasMitm"},
|
||||
{65005, nullptr, "AtmosphereWaitMitm"},
|
||||
{65006, nullptr, "AtmosphereDeclareFutureMitm"},
|
||||
{65100, &SM::AtmosphereHasService, "AtmosphereHasService"},
|
||||
{65101, nullptr, "AtmosphereWaitService"},
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue