For ia64, use pmap_remove_pages() and not pmap_remove(). The problem is

that we don't have a good way (yet) to iterate over the mapped pages by
virtual address and simply try each page within the range. Given that we
call pmap_remove() over the entire 2^63 bytes of address space, it takes
a while for pmap_remove to have tried all 2^50 pages.
By using pmap_remove_pages() we use the PV list to find all mappings.

Change derived from a patch by: alc
This commit is contained in:
Marcel Moolenaar 2013-12-26 05:46:10 +00:00
parent 7091cd69d0
commit 938b0f5b75

View File

@ -875,6 +875,14 @@ vm_pageout_map_deactivate_pages(map, desired)
tmpe = tmpe->next;
}
#ifdef __ia64__
/*
* Remove all non-wired, managed mappings if a process is swapped out.
* This will free page table pages.
*/
if (desired == 0)
pmap_remove_pages(map->pmap);
#else
/*
* Remove all mappings if a process is swapped out, this will free page
* table pages.
@ -883,6 +891,8 @@ vm_pageout_map_deactivate_pages(map, desired)
pmap_remove(vm_map_pmap(map), vm_map_min(map),
vm_map_max(map));
}
#endif
vm_map_unlock(map);
}
#endif /* !defined(NO_SWAPPING) */