diff options
| author | 2022-03-12 13:02:45 -0800 | |
|---|---|---|
| committer | 2022-03-14 18:14:54 -0700 | |
| commit | e95bb782f08511cf6fa23c473e97c4861772dc39 (patch) | |
| tree | 81962a3fc13b93b4b642715c142a0f32a82e033b /src | |
| parent | core: hle: kernel: Allocate dummy threads on host thread storage. (diff) | |
| download | yuzu-e95bb782f08511cf6fa23c473e97c4861772dc39.tar.gz yuzu-e95bb782f08511cf6fa23c473e97c4861772dc39.tar.xz yuzu-e95bb782f08511cf6fa23c473e97c4861772dc39.zip | |
core: hle: kernel: init_slab_setup: Move CalculateSlabHeapGapSize to global namespace.
Diffstat (limited to '')
| -rw-r--r-- | src/core/hle/kernel/init/init_slab_setup.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/core/hle/kernel/init/init_slab_setup.cpp b/src/core/hle/kernel/init/init_slab_setup.cpp index 4e60f0829..b0f773ee0 100644 --- a/src/core/hle/kernel/init/init_slab_setup.cpp +++ b/src/core/hle/kernel/init/init_slab_setup.cpp | |||
| @@ -107,6 +107,12 @@ VAddr InitializeSlabHeap(Core::System& system, KMemoryLayout& memory_layout, VAd | |||
| 107 | return start + size; | 107 | return start + size; |
| 108 | } | 108 | } |
| 109 | 109 | ||
| 110 | size_t CalculateSlabHeapGapSize() { | ||
| 111 | constexpr size_t KernelSlabHeapGapSize = 2_MiB - 296_KiB; | ||
| 112 | static_assert(KernelSlabHeapGapSize <= KernelSlabHeapGapsSizeMax); | ||
| 113 | return KernelSlabHeapGapSize; | ||
| 114 | } | ||
| 115 | |||
| 110 | } // namespace | 116 | } // namespace |
| 111 | 117 | ||
| 112 | KSlabResourceCounts KSlabResourceCounts::CreateDefault() { | 118 | KSlabResourceCounts KSlabResourceCounts::CreateDefault() { |
| @@ -137,12 +143,6 @@ void InitializeSlabResourceCounts(KernelCore& kernel) { | |||
| 137 | } | 143 | } |
| 138 | } | 144 | } |
| 139 | 145 | ||
| 140 | size_t CalculateSlabHeapGapSize() { | ||
| 141 | constexpr size_t KernelSlabHeapGapSize = 2_MiB - 296_KiB; | ||
| 142 | static_assert(KernelSlabHeapGapSize <= KernelSlabHeapGapsSizeMax); | ||
| 143 | return KernelSlabHeapGapSize; | ||
| 144 | } | ||
| 145 | |||
| 146 | size_t CalculateTotalSlabHeapSize(const KernelCore& kernel) { | 146 | size_t CalculateTotalSlabHeapSize(const KernelCore& kernel) { |
| 147 | size_t size = 0; | 147 | size_t size = 0; |
| 148 | 148 | ||