diff options
author | itsmeft24 <rishabh.tumminkatti@gmail.com> | 2021-12-05 21:04:08 +0100 |
---|---|---|
committer | itsmeft24 <rishabh.tumminkatti@gmail.com> | 2021-12-05 21:04:08 +0100 |
commit | 8aef8f39d86affd8fcc9a812d3d597f8eaee90b8 (patch) | |
tree | c0249fef800fad1f0ad0b027b85a1801ac41e294 /src/core/hle/kernel/k_page_table.h | |
parent | Merge pull request #7494 from Morph1984/no-time-to-wait (diff) | |
download | yuzu-8aef8f39d86affd8fcc9a812d3d597f8eaee90b8.tar yuzu-8aef8f39d86affd8fcc9a812d3d597f8eaee90b8.tar.gz yuzu-8aef8f39d86affd8fcc9a812d3d597f8eaee90b8.tar.bz2 yuzu-8aef8f39d86affd8fcc9a812d3d597f8eaee90b8.tar.lz yuzu-8aef8f39d86affd8fcc9a812d3d597f8eaee90b8.tar.xz yuzu-8aef8f39d86affd8fcc9a812d3d597f8eaee90b8.tar.zst yuzu-8aef8f39d86affd8fcc9a812d3d597f8eaee90b8.zip |
Diffstat (limited to 'src/core/hle/kernel/k_page_table.h')
-rw-r--r-- | src/core/hle/kernel/k_page_table.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/hle/kernel/k_page_table.h b/src/core/hle/kernel/k_page_table.h index b7ec38f06..d784aa67e 100644 --- a/src/core/hle/kernel/k_page_table.h +++ b/src/core/hle/kernel/k_page_table.h @@ -33,6 +33,8 @@ public: KMemoryPermission perm); ResultCode MapProcessCodeMemory(VAddr dst_addr, VAddr src_addr, std::size_t size); ResultCode UnmapProcessCodeMemory(VAddr dst_addr, VAddr src_addr, std::size_t size); + ResultCode UnmapProcessMemory(VAddr dst_addr, std::size_t size, KPageTable& src_page_table, + VAddr src_addr); ResultCode MapPhysicalMemory(VAddr addr, std::size_t size); ResultCode UnmapPhysicalMemory(VAddr addr, std::size_t size); ResultCode UnmapMemory(VAddr addr, std::size_t size); @@ -55,6 +57,8 @@ public: KMemoryPermission perm, PAddr map_addr = 0); ResultCode LockForDeviceAddressSpace(VAddr addr, std::size_t size); ResultCode UnlockForDeviceAddressSpace(VAddr addr, std::size_t size); + ResultCode LockForCodeMemory(VAddr addr, std::size_t size); + ResultCode UnlockForCodeMemory(VAddr addr, std::size_t size); Common::PageTable& PageTableImpl() { return page_table_impl; @@ -115,6 +119,10 @@ private: return CheckMemoryState(nullptr, nullptr, nullptr, addr, size, state_mask, state, perm_mask, perm, attr_mask, attr, ignore_attr); } + ResultCode CheckMemoryState(size_t* out_blocks_needed, VAddr addr, size_t size, + KMemoryState state_mask, KMemoryState state, + KMemoryPermission perm_mask, KMemoryPermission perm, + KMemoryAttribute attr_mask, KMemoryAttribute attr) const; std::recursive_mutex page_table_lock; std::unique_ptr<KMemoryBlockManager> block_manager; |