From c02b8c895b49b511a4316ee5e7bf1ab9a081869b Mon Sep 17 00:00:00 2001 From: Lioncash Date: Wed, 12 Dec 2018 11:04:10 -0500 Subject: vm_manager: Migrate MemoryInfo and PageInfo to vm_manager.h Gets the two structures out of an unrelated header and places them with the rest of the memory management code. This also corrects the structures. PageInfo appears to only contain a 32-bit flags member, and the extra padding word in MemoryInfo isn't necessary. --- src/core/hle/kernel/vm_manager.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'src/core/hle/kernel/vm_manager.h') diff --git a/src/core/hle/kernel/vm_manager.h b/src/core/hle/kernel/vm_manager.h index 0a600c23c..35f0f276e 100644 --- a/src/core/hle/kernel/vm_manager.h +++ b/src/core/hle/kernel/vm_manager.h @@ -150,6 +150,21 @@ constexpr u32 ToSvcMemoryState(MemoryState state) { return static_cast(state & MemoryState::Mask); } +struct MemoryInfo { + u64 base_address; + u64 size; + u32 type; + u32 attributes; + u32 permission; + u32 device_refcount; + u32 ipc_refcount; +}; +static_assert(sizeof(MemoryInfo) == 0x28, "MemoryInfo has incorrect size."); + +struct PageInfo { + u32 flags; +}; + /** * Represents a VMA in an address space. A VMA is a contiguous region of virtual addressing space * with homogeneous attributes across its extents. In this particular implementation each VMA is -- cgit v1.2.3