diff options
author | liamwhite <liamwhite@users.noreply.github.com> | 2024-02-23 02:26:03 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-02-23 02:26:03 +0100 |
commit | dad9ea3e076763cbfd0c29497552531cb7c45edf (patch) | |
tree | 0667e704694d156a6878e45d609a72c2f2f484ba /src/core/hle/service/psc/psc.cpp | |
parent | Merge pull request #12982 from FearlessTobi/fs-rewrite-part0 (diff) | |
parent | psc: stub overlay notification channel (diff) | |
download | yuzu-dad9ea3e076763cbfd0c29497552531cb7c45edf.tar yuzu-dad9ea3e076763cbfd0c29497552531cb7c45edf.tar.gz yuzu-dad9ea3e076763cbfd0c29497552531cb7c45edf.tar.bz2 yuzu-dad9ea3e076763cbfd0c29497552531cb7c45edf.tar.lz yuzu-dad9ea3e076763cbfd0c29497552531cb7c45edf.tar.xz yuzu-dad9ea3e076763cbfd0c29497552531cb7c45edf.tar.zst yuzu-dad9ea3e076763cbfd0c29497552531cb7c45edf.zip |
Diffstat (limited to 'src/core/hle/service/psc/psc.cpp')
-rw-r--r-- | src/core/hle/service/psc/psc.cpp | 71 |
1 files changed, 6 insertions, 65 deletions
diff --git a/src/core/hle/service/psc/psc.cpp b/src/core/hle/service/psc/psc.cpp index 44310756b..e1762d694 100644 --- a/src/core/hle/service/psc/psc.cpp +++ b/src/core/hle/service/psc/psc.cpp @@ -1,11 +1,10 @@ // SPDX-FileCopyrightText: Copyright 2018 yuzu Emulator Project // SPDX-License-Identifier: GPL-2.0-or-later -#include <memory> - -#include "common/logging/log.h" -#include "core/core.h" -#include "core/hle/service/ipc_helpers.h" +#include "core/hle/service/psc/ovln/receiver_service.h" +#include "core/hle/service/psc/ovln/sender_service.h" +#include "core/hle/service/psc/pm_control.h" +#include "core/hle/service/psc/pm_service.h" #include "core/hle/service/psc/psc.h" #include "core/hle/service/psc/time/manager.h" #include "core/hle/service/psc/time/power_state_service.h" @@ -15,71 +14,13 @@ namespace Service::PSC { -class IPmControl final : public ServiceFramework<IPmControl> { -public: - explicit IPmControl(Core::System& system_) : ServiceFramework{system_, "psc:c"} { - // clang-format off - static const FunctionInfo functions[] = { - {0, nullptr, "Initialize"}, - {1, nullptr, "DispatchRequest"}, - {2, nullptr, "GetResult"}, - {3, nullptr, "GetState"}, - {4, nullptr, "Cancel"}, - {5, nullptr, "PrintModuleInformation"}, - {6, nullptr, "GetModuleInformation"}, - {10, nullptr, "AcquireStateLock"}, - {11, nullptr, "HasStateLock"}, - }; - // clang-format on - - RegisterHandlers(functions); - } -}; - -class IPmModule final : public ServiceFramework<IPmModule> { -public: - explicit IPmModule(Core::System& system_) : ServiceFramework{system_, "IPmModule"} { - // clang-format off - static const FunctionInfo functions[] = { - {0, nullptr, "Initialize"}, - {1, nullptr, "GetRequest"}, - {2, nullptr, "Acknowledge"}, - {3, nullptr, "Finalize"}, - {4, nullptr, "AcknowledgeEx"}, - }; - // clang-format on - - RegisterHandlers(functions); - } -}; - -class IPmService final : public ServiceFramework<IPmService> { -public: - explicit IPmService(Core::System& system_) : ServiceFramework{system_, "psc:m"} { - // clang-format off - static const FunctionInfo functions[] = { - {0, &IPmService::GetPmModule, "GetPmModule"}, - }; - // clang-format on - - RegisterHandlers(functions); - } - -private: - void GetPmModule(HLERequestContext& ctx) { - LOG_DEBUG(Service_PSC, "called"); - - IPC::ResponseBuilder rb{ctx, 2, 0, 1}; - rb.Push(ResultSuccess); - rb.PushIpcInterface<IPmModule>(system); - } -}; - void LoopProcess(Core::System& system) { auto server_manager = std::make_unique<ServerManager>(system); server_manager->RegisterNamedService("psc:c", std::make_shared<IPmControl>(system)); server_manager->RegisterNamedService("psc:m", std::make_shared<IPmService>(system)); + server_manager->RegisterNamedService("ovln:rcv", std::make_shared<IReceiverService>(system)); + server_manager->RegisterNamedService("ovln:snd", std::make_shared<ISenderService>(system)); auto time = std::make_shared<Time::TimeManager>(system); |