diff options
| author | 2023-02-18 16:26:48 -0500 | |
|---|---|---|
| committer | 2023-02-21 12:19:25 -0500 | |
| commit | a9369726147c7499e0016e183d5d56a7b44efe4b (patch) | |
| tree | c1d1b4a9fdafd92863c0922b05d72c14de83ffa7 /src/core/hle/service/psc | |
| parent | core: defer cpu shutdown (diff) | |
| download | yuzu-a9369726147c7499e0016e183d5d56a7b44efe4b.tar.gz yuzu-a9369726147c7499e0016e183d5d56a7b44efe4b.tar.xz yuzu-a9369726147c7499e0016e183d5d56a7b44efe4b.zip | |
service: refactor server architecture
Converts services to have their own processes
Diffstat (limited to 'src/core/hle/service/psc')
| -rw-r--r-- | src/core/hle/service/psc/psc.cpp | 11 | ||||
| -rw-r--r-- | src/core/hle/service/psc/psc.h | 2 |
2 files changed, 8 insertions, 5 deletions
diff --git a/src/core/hle/service/psc/psc.cpp b/src/core/hle/service/psc/psc.cpp index 3a9412cf5..1650d2f39 100644 --- a/src/core/hle/service/psc/psc.cpp +++ b/src/core/hle/service/psc/psc.cpp | |||
| @@ -6,8 +6,8 @@ | |||
| 6 | #include "common/logging/log.h" | 6 | #include "common/logging/log.h" |
| 7 | #include "core/hle/ipc_helpers.h" | 7 | #include "core/hle/ipc_helpers.h" |
| 8 | #include "core/hle/service/psc/psc.h" | 8 | #include "core/hle/service/psc/psc.h" |
| 9 | #include "core/hle/service/server_manager.h" | ||
| 9 | #include "core/hle/service/service.h" | 10 | #include "core/hle/service/service.h" |
| 10 | #include "core/hle/service/sm/sm.h" | ||
| 11 | 11 | ||
| 12 | namespace Service::PSC { | 12 | namespace Service::PSC { |
| 13 | 13 | ||
| @@ -71,9 +71,12 @@ private: | |||
| 71 | } | 71 | } |
| 72 | }; | 72 | }; |
| 73 | 73 | ||
| 74 | void InstallInterfaces(SM::ServiceManager& sm, Core::System& system) { | 74 | void LoopProcess(Core::System& system) { |
| 75 | std::make_shared<PSC_C>(system)->InstallAsService(sm); | 75 | auto server_manager = std::make_unique<ServerManager>(system); |
| 76 | std::make_shared<PSC_M>(system)->InstallAsService(sm); | 76 | |
| 77 | server_manager->RegisterNamedService("psc:c", std::make_shared<PSC_C>(system)); | ||
| 78 | server_manager->RegisterNamedService("psc:m", std::make_shared<PSC_M>(system)); | ||
| 79 | ServerManager::RunServer(std::move(server_manager)); | ||
| 77 | } | 80 | } |
| 78 | 81 | ||
| 79 | } // namespace Service::PSC | 82 | } // namespace Service::PSC |
diff --git a/src/core/hle/service/psc/psc.h b/src/core/hle/service/psc/psc.h index d248372c2..459137f42 100644 --- a/src/core/hle/service/psc/psc.h +++ b/src/core/hle/service/psc/psc.h | |||
| @@ -13,6 +13,6 @@ class ServiceManager; | |||
| 13 | 13 | ||
| 14 | namespace Service::PSC { | 14 | namespace Service::PSC { |
| 15 | 15 | ||
| 16 | void InstallInterfaces(SM::ServiceManager& sm, Core::System& system); | 16 | void LoopProcess(Core::System& system); |
| 17 | 17 | ||
| 18 | } // namespace Service::PSC | 18 | } // namespace Service::PSC |