mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-06-15 08:07:56 -05:00
address review commentary
This commit is contained in:
@ -349,7 +349,7 @@ ResultCode VMManager::MapPhysicalMemory(VAddr target, u64 size) {
|
||||
}
|
||||
|
||||
// Check that we can map the memory we want.
|
||||
const auto res_limit = Core::CurrentProcess()->GetResourceLimit();
|
||||
const auto res_limit = system.CurrentProcess()->GetResourceLimit();
|
||||
const u64 physmem_remaining = res_limit->GetMaxResourceValue(ResourceType::PhysicalMemory) -
|
||||
res_limit->GetCurrentResourceValue(ResourceType::PhysicalMemory);
|
||||
if (physmem_remaining < (size - mapped_size)) {
|
||||
@ -558,6 +558,9 @@ ResultCode VMManager::UnmapPhysicalMemory(VAddr target, u64 size) {
|
||||
}
|
||||
}
|
||||
|
||||
// Update mapped amount
|
||||
physical_memory_mapped -= mapped_size;
|
||||
|
||||
return RESULT_SUCCESS;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user