diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/hle/kernel/board/nintendo/nx/k_system_control.cpp | 24 |
1 files changed, 4 insertions, 20 deletions
diff --git a/src/core/hle/kernel/board/nintendo/nx/k_system_control.cpp b/src/core/hle/kernel/board/nintendo/nx/k_system_control.cpp index 6f335c251..702cacffc 100644 --- a/src/core/hle/kernel/board/nintendo/nx/k_system_control.cpp +++ b/src/core/hle/kernel/board/nintendo/nx/k_system_control.cpp | |||
| @@ -5,6 +5,7 @@ | |||
| 5 | #include <random> | 5 | #include <random> |
| 6 | 6 | ||
| 7 | #include "common/literals.h" | 7 | #include "common/literals.h" |
| 8 | #include "common/settings.h" | ||
| 8 | 9 | ||
| 9 | #include "core/hle/kernel/board/nintendo/nx/k_system_control.h" | 10 | #include "core/hle/kernel/board/nintendo/nx/k_system_control.h" |
| 10 | #include "core/hle/kernel/board/nintendo/nx/secure_monitor.h" | 11 | #include "core/hle/kernel/board/nintendo/nx/secure_monitor.h" |
| @@ -28,30 +29,13 @@ namespace { | |||
| 28 | 29 | ||
| 29 | using namespace Common::Literals; | 30 | using namespace Common::Literals; |
| 30 | 31 | ||
| 31 | u32 GetMemoryModeForInit() { | ||
| 32 | return 0x01; | ||
| 33 | } | ||
| 34 | |||
| 35 | u32 GetMemorySizeForInit() { | 32 | u32 GetMemorySizeForInit() { |
| 36 | return 0; | 33 | return Settings::values.use_extended_memory_layout ? Smc::MemorySize_6GB : Smc::MemorySize_4GB; |
| 37 | } | 34 | } |
| 38 | 35 | ||
| 39 | Smc::MemoryArrangement GetMemoryArrangeForInit() { | 36 | Smc::MemoryArrangement GetMemoryArrangeForInit() { |
| 40 | switch (GetMemoryModeForInit() & 0x3F) { | 37 | return Settings::values.use_extended_memory_layout ? Smc::MemoryArrangement_6GB |
| 41 | case 0x01: | 38 | : Smc::MemoryArrangement_4GB; |
| 42 | default: | ||
| 43 | return Smc::MemoryArrangement_4GB; | ||
| 44 | case 0x02: | ||
| 45 | return Smc::MemoryArrangement_4GBForAppletDev; | ||
| 46 | case 0x03: | ||
| 47 | return Smc::MemoryArrangement_4GBForSystemDev; | ||
| 48 | case 0x11: | ||
| 49 | return Smc::MemoryArrangement_6GB; | ||
| 50 | case 0x12: | ||
| 51 | return Smc::MemoryArrangement_6GBForAppletDev; | ||
| 52 | case 0x21: | ||
| 53 | return Smc::MemoryArrangement_8GB; | ||
| 54 | } | ||
| 55 | } | 39 | } |
| 56 | } // namespace | 40 | } // namespace |
| 57 | 41 | ||