vm: allow 4k-aligned allocations for vm::stack

Fix utils::shm::map logic for MapViewOfFileEx
This commit is contained in:
Nekotekina 2018-08-27 17:52:47 +03:00
parent c49c7de427
commit 85fa0942e7
4 changed files with 117 additions and 37 deletions

View file

@ -146,7 +146,10 @@ namespace vm
// Mapped regions: addr -> shm handle
std::map<u32, std::shared_ptr<utils::shm>> m_map;
bool try_alloc(u32 addr, u8 flags, std::shared_ptr<utils::shm>&&);
// Common mapped region for special cases
std::shared_ptr<utils::shm> m_common;
bool try_alloc(u32 addr, u8 flags, u32 size, std::shared_ptr<utils::shm>&&);
public:
block_t(u32 addr, u32 size, u64 flags = 0);