summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2022-03-26 09:35:37 +0100
committerbunnei <bunneidev@gmail.com>2022-03-26 09:35:37 +0100
commit1b3dba329aaf4bcaecefb8edde504f5087727689 (patch)
tree9f7254817b314d502b6a8a54df6172ede2e84d39 /src
parenthle: kernel: svc: CreateCodeMemory: Remove log of 'out' host pointer. (diff)
downloadyuzu-1b3dba329aaf4bcaecefb8edde504f5087727689.tar
yuzu-1b3dba329aaf4bcaecefb8edde504f5087727689.tar.gz
yuzu-1b3dba329aaf4bcaecefb8edde504f5087727689.tar.bz2
yuzu-1b3dba329aaf4bcaecefb8edde504f5087727689.tar.lz
yuzu-1b3dba329aaf4bcaecefb8edde504f5087727689.tar.xz
yuzu-1b3dba329aaf4bcaecefb8edde504f5087727689.tar.zst
yuzu-1b3dba329aaf4bcaecefb8edde504f5087727689.zip
Diffstat (limited to 'src')
-rw-r--r--src/core/hle/kernel/svc.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/core/hle/kernel/svc.cpp b/src/core/hle/kernel/svc.cpp
index 4a2115e2d..976d63234 100644
--- a/src/core/hle/kernel/svc.cpp
+++ b/src/core/hle/kernel/svc.cpp
@@ -1362,8 +1362,11 @@ static ResultCode MapProcessMemory(Core::System& system, VAddr dst_address, Hand
ResultInvalidMemoryRegion);
// Create a new page group.
- KMemoryInfo kBlockInfo = dst_pt.QueryInfo(dst_address);
- KPageLinkedList pg(kBlockInfo.GetAddress(), kBlockInfo.GetNumPages());
+ KPageLinkedList pg;
+ R_TRY(src_pt.MakeAndOpenPageGroup(
+ std::addressof(pg), src_address, size / PageSize, KMemoryState::FlagCanMapProcess,
+ KMemoryState::FlagCanMapProcess, KMemoryPermission::None, KMemoryPermission::None,
+ KMemoryAttribute::All, KMemoryAttribute::None));
// Map the group.
R_TRY(dst_pt.MapPages(dst_address, pg, KMemoryState::SharedCode,