diff options
author | bunnei <bunneidev@gmail.com> | 2021-02-21 06:15:00 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-02-21 06:15:00 +0100 |
commit | 3d0394681c07fddc48cdee956329db89254b763d (patch) | |
tree | 15e4fc8fb15f1d574063d89649c62bda74ac02b2 /src | |
parent | Merge pull request #5965 from Morph1984/shader-count (diff) | |
parent | kernel: Fix resource release exception on exit (diff) | |
download | yuzu-3d0394681c07fddc48cdee956329db89254b763d.tar yuzu-3d0394681c07fddc48cdee956329db89254b763d.tar.gz yuzu-3d0394681c07fddc48cdee956329db89254b763d.tar.bz2 yuzu-3d0394681c07fddc48cdee956329db89254b763d.tar.lz yuzu-3d0394681c07fddc48cdee956329db89254b763d.tar.xz yuzu-3d0394681c07fddc48cdee956329db89254b763d.tar.zst yuzu-3d0394681c07fddc48cdee956329db89254b763d.zip |
Diffstat (limited to '')
-rw-r--r-- | src/core/core.cpp | 3 | ||||
-rw-r--r-- | src/core/hle/kernel/kernel.cpp | 9 | ||||
-rw-r--r-- | src/core/hle/service/time/time_manager.cpp | 4 | ||||
-rw-r--r-- | src/core/hle/service/time/time_manager.h | 2 |
4 files changed, 16 insertions, 2 deletions
diff --git a/src/core/core.cpp b/src/core/core.cpp index 30f5e1128..de6305e2a 100644 --- a/src/core/core.cpp +++ b/src/core/core.cpp @@ -308,6 +308,9 @@ struct System::Impl { // Close all CPU/threading state cpu_manager.Shutdown(); + // Release the Time Manager's resources + time_manager.Shutdown(); + // Shutdown kernel and core timing core_timing.Shutdown(); kernel.Shutdown(); diff --git a/src/core/hle/kernel/kernel.cpp b/src/core/hle/kernel/kernel.cpp index b6e6f115e..39c5182c5 100644 --- a/src/core/hle/kernel/kernel.cpp +++ b/src/core/hle/kernel/kernel.cpp @@ -101,8 +101,6 @@ struct KernelCore::Impl { current_process = nullptr; - system_resource_limit = nullptr; - global_handle_table.Clear(); preemption_event = nullptr; @@ -111,6 +109,13 @@ struct KernelCore::Impl { exclusive_monitor.reset(); + hid_shared_mem = nullptr; + font_shared_mem = nullptr; + irs_shared_mem = nullptr; + time_shared_mem = nullptr; + + system_resource_limit = nullptr; + // Next host thead ID to use, 0-3 IDs represent core threads, >3 represent others next_host_thread_id = Core::Hardware::NUM_CPU_CORES; } diff --git a/src/core/hle/service/time/time_manager.cpp b/src/core/hle/service/time/time_manager.cpp index 858623e2b..1f7309f6b 100644 --- a/src/core/hle/service/time/time_manager.cpp +++ b/src/core/hle/service/time/time_manager.cpp @@ -279,6 +279,10 @@ const SharedMemory& TimeManager::GetSharedMemory() const { return impl->shared_memory; } +void TimeManager::Shutdown() { + impl.reset(); +} + void TimeManager::UpdateLocalSystemClockTime(s64 posix_time) { impl->UpdateLocalSystemClockTime(system, posix_time); } diff --git a/src/core/hle/service/time/time_manager.h b/src/core/hle/service/time/time_manager.h index 993c7c288..4db8cc0e1 100644 --- a/src/core/hle/service/time/time_manager.h +++ b/src/core/hle/service/time/time_manager.h @@ -61,6 +61,8 @@ public: const SharedMemory& GetSharedMemory() const; + void Shutdown(); + void SetupTimeZoneManager(std::string location_name, Clock::SteadyClockTimePoint time_zone_updated_time_point, std::size_t total_location_name_count, u128 time_zone_rule_version, |