diff options
author | bunnei <bunneidev@gmail.com> | 2020-11-24 23:31:58 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-11-24 23:31:58 +0100 |
commit | 7791cc8c2e585dcc377e22a26f548db914250a5d (patch) | |
tree | 81273d60fee9da0146317881711b6f0b43650355 /src/core/hle/service/service.cpp | |
parent | Merge pull request #3681 from lioncash/component (diff) | |
download | yuzu-7791cc8c2e585dcc377e22a26f548db914250a5d.tar yuzu-7791cc8c2e585dcc377e22a26f548db914250a5d.tar.gz yuzu-7791cc8c2e585dcc377e22a26f548db914250a5d.tar.bz2 yuzu-7791cc8c2e585dcc377e22a26f548db914250a5d.tar.lz yuzu-7791cc8c2e585dcc377e22a26f548db914250a5d.tar.xz yuzu-7791cc8c2e585dcc377e22a26f548db914250a5d.tar.zst yuzu-7791cc8c2e585dcc377e22a26f548db914250a5d.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/hle/service/service.cpp | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/src/core/hle/service/service.cpp b/src/core/hle/service/service.cpp index fbfda2d5b..fb4979af2 100644 --- a/src/core/hle/service/service.cpp +++ b/src/core/hle/service/service.cpp @@ -188,17 +188,19 @@ ResultCode ServiceFrameworkBase::HandleSyncRequest(Kernel::HLERequestContext& co return RESULT_SUCCESS; } -/// Initialize ServiceManager -void Init(std::shared_ptr<SM::ServiceManager>& sm, Core::System& system) { +/// Initialize Services +Services::Services(std::shared_ptr<SM::ServiceManager>& sm, Core::System& system) + : nv_flinger{std::make_unique<NVFlinger::NVFlinger>(system)} { + // NVFlinger needs to be accessed by several services like Vi and AppletOE so we instantiate it // here and pass it into the respective InstallInterfaces functions. - auto nv_flinger = std::make_shared<NVFlinger::NVFlinger>(system); + system.GetFileSystemController().CreateFactories(*system.GetFilesystem(), false); SM::ServiceManager::InstallInterfaces(sm, system.Kernel()); Account::InstallInterfaces(system); - AM::InstallInterfaces(*sm, nv_flinger, system); + AM::InstallInterfaces(*sm, *nv_flinger, system); AOC::InstallInterfaces(*sm, system); APM::InstallInterfaces(system); Audio::InstallInterfaces(*sm, system); @@ -246,14 +248,10 @@ void Init(std::shared_ptr<SM::ServiceManager>& sm, Core::System& system) { SSL::InstallInterfaces(*sm); Time::InstallInterfaces(system); USB::InstallInterfaces(*sm); - VI::InstallInterfaces(*sm, nv_flinger); + VI::InstallInterfaces(*sm, *nv_flinger); WLAN::InstallInterfaces(*sm); - - LOG_DEBUG(Service, "initialized OK"); } -/// Shutdown ServiceManager -void Shutdown() { - LOG_DEBUG(Service, "shutdown OK"); -} +Services::~Services() = default; + } // namespace Service |