VMM: When unmapping a page, invalidate the TLB for that page

This commit is contained in:
apio 2022-10-12 14:24:34 +02:00
parent c9ebe89899
commit 525d567af6

View File

@ -57,6 +57,8 @@ namespace Paging
PDE = PT->entries[P_i]; PDE = PT->entries[P_i];
PDE.Present = false; PDE.Present = false;
PT->entries[P_i] = PDE; PT->entries[P_i] = PDE;
invalidate:
asm volatile("invlpg (%0)" : : "r"(virtualAddress) : "memory");
} }
uint64_t VirtualMemoryManager::getPhysical(uint64_t virtualAddress) uint64_t VirtualMemoryManager::getPhysical(uint64_t virtualAddress)