diff options
| author | 2019-02-14 12:42:58 -0500 | |
|---|---|---|
| committer | 2019-02-15 21:50:25 -0500 | |
| commit | bd983414f643b734a1f8bebe3183723733344f72 (patch) | |
| tree | bda0421458439e25cba9d772a6a79b56e473d72e /src/core/hle/service/service.cpp | |
| parent | Merge pull request #2113 from ReinUsesLisp/vulkan-base (diff) | |
| download | yuzu-bd983414f643b734a1f8bebe3183723733344f72.tar.gz yuzu-bd983414f643b734a1f8bebe3183723733344f72.tar.xz yuzu-bd983414f643b734a1f8bebe3183723733344f72.zip | |
core_timing: Convert core timing into a class
Gets rid of the largest set of mutable global state within the core.
This also paves a way for eliminating usages of GetInstance() on the
System class as a follow-up.
Note that no behavioral changes have been made, and this simply extracts
the functionality into a class. This also has the benefit of making
dependencies on the core timing functionality explicit within the
relevant interfaces.
Diffstat (limited to 'src/core/hle/service/service.cpp')
| -rw-r--r-- | src/core/hle/service/service.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/core/hle/service/service.cpp b/src/core/hle/service/service.cpp index d25b80ab0..117f87a45 100644 --- a/src/core/hle/service/service.cpp +++ b/src/core/hle/service/service.cpp | |||
| @@ -194,10 +194,11 @@ ResultCode ServiceFrameworkBase::HandleSyncRequest(Kernel::HLERequestContext& co | |||
| 194 | // Module interface | 194 | // Module interface |
| 195 | 195 | ||
| 196 | /// Initialize ServiceManager | 196 | /// Initialize ServiceManager |
| 197 | void Init(std::shared_ptr<SM::ServiceManager>& sm, FileSys::VfsFilesystem& vfs) { | 197 | void Init(std::shared_ptr<SM::ServiceManager>& sm, Core::System& system, |
| 198 | FileSys::VfsFilesystem& vfs) { | ||
| 198 | // NVFlinger needs to be accessed by several services like Vi and AppletOE so we instantiate it | 199 | // NVFlinger needs to be accessed by several services like Vi and AppletOE so we instantiate it |
| 199 | // here and pass it into the respective InstallInterfaces functions. | 200 | // here and pass it into the respective InstallInterfaces functions. |
| 200 | auto nv_flinger = std::make_shared<NVFlinger::NVFlinger>(); | 201 | auto nv_flinger = std::make_shared<NVFlinger::NVFlinger>(system.CoreTiming()); |
| 201 | 202 | ||
| 202 | SM::ServiceManager::InstallInterfaces(sm); | 203 | SM::ServiceManager::InstallInterfaces(sm); |
| 203 | 204 | ||