1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 06:38:10 +00:00

x86: Simplify region unmapping a bit

Add PageTableEntry::clear() to zero out a whole PTE, and use that for
unmapping instead of clearing individual fields.
This commit is contained in:
Andreas Kling 2020-02-08 12:49:00 +01:00
parent 3b95d61b22
commit a9d7902bb7
3 changed files with 5 additions and 8 deletions

View file

@ -559,8 +559,7 @@ void MemoryManager::unquickmap_page()
ASSERT_INTERRUPTS_DISABLED();
ASSERT(m_quickmap_in_use);
auto& pte = boot_pd3_pde1023_pt[0];
pte.set_physical_page_base(0);
pte.set_present(false);
pte.clear();
flush_tlb(VirtualAddress(0xffe00000));
m_quickmap_in_use = false;
}