summaryrefslogtreecommitdiff
path: root/src/core/loader/nro.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/loader/nro.cpp')
-rw-r--r--src/core/loader/nro.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/loader/nro.cpp b/src/core/loader/nro.cpp
index 76ff38041..49d4d7e43 100644
--- a/src/core/loader/nro.cpp
+++ b/src/core/loader/nro.cpp
@@ -204,7 +204,7 @@ static bool LoadNroImpl(Core::System& system, Kernel::KProcess& process,
204#ifdef ARCHITECTURE_arm64 204#ifdef ARCHITECTURE_arm64
205 const auto& code = codeset.CodeSegment(); 205 const auto& code = codeset.CodeSegment();
206 206
207 // NROs are always 64-bit programs. 207 // NROs always have a 39-bit address space.
208 Settings::SetNceEnabled(true); 208 Settings::SetNceEnabled(true);
209 209
210 // Create NCE patcher 210 // Create NCE patcher
@@ -215,12 +215,12 @@ static bool LoadNroImpl(Core::System& system, Kernel::KProcess& process,
215 patch.PatchText(program_image, code); 215 patch.PatchText(program_image, code);
216 216
217 // We only support PostData patching for NROs. 217 // We only support PostData patching for NROs.
218 ASSERT(patch.Mode() == Core::NCE::PatchMode::PostData); 218 ASSERT(patch.GetPatchMode() == Core::NCE::PatchMode::PostData);
219 219
220 // Update patch section. 220 // Update patch section.
221 auto& patch_segment = codeset.PatchSegment(); 221 auto& patch_segment = codeset.PatchSegment();
222 patch_segment.addr = image_size; 222 patch_segment.addr = image_size;
223 patch_segment.size = static_cast<u32>(patch.SectionSize()); 223 patch_segment.size = static_cast<u32>(patch.GetSectionSize());
224 224
225 // Add patch section size to the module size. 225 // Add patch section size to the module size.
226 image_size += patch_segment.size; 226 image_size += patch_segment.size;