mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-07 17:15:26 +00:00
Kernel: Always give back VM to the RangeAllocator when unmapping Region
We were only doing this in Process::deallocate_region(), which meant that kernel-only Regions never gave back their VM. With this patch, we can start reusing freed-up address space! :^)
This commit is contained in:
@@ -142,7 +142,6 @@ bool Process::deallocate_region(Region& region)
|
||||
InterruptDisabler disabler;
|
||||
for (int i = 0; i < m_regions.size(); ++i) {
|
||||
if (&m_regions[i] == ®ion) {
|
||||
page_directory().range_allocator().deallocate({ region.vaddr(), region.size() });
|
||||
MM.unmap_region(region);
|
||||
m_regions.remove(i);
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user