Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pagecache: use an objcache as page heap
In the pagecache code, allocating 4KB pages directly from the linear backed heap creates excessive fragmentation, which in low-memory conditions may cause other allocations in the kernel (which typically use objcaches with a 2MB page size) to fail even when pagecache drain requests are fully executed. This commit addresses the fragmentation issue by changing the pagecache code to use an objcache (with a 2MB page size, and with the linear backed heap as parent heap) as page heap; this allows a pagecache drain to release memory in large chunks that are then available for other allocation requests throughout the kernel. In addition, the pagecache completion heap is now drained if a drain request could not be fully executed by draining the page heap.
- Loading branch information