Page MenuHomeFreeBSD

device_pager: user iterators to free device pages
ClosedPublic

Authored by dougm on Nov 20 2024, 11:45 PM.
Tags
None
Referenced Files
F107522865: D47692.diff
Wed, Jan 15, 9:58 AM
Unknown Object (File)
Sun, Dec 22, 11:57 PM
Unknown Object (File)
Dec 3 2024, 11:03 PM
Unknown Object (File)
Dec 3 2024, 3:30 PM
Unknown Object (File)
Dec 3 2024, 4:04 AM
Unknown Object (File)
Dec 2 2024, 4:13 PM
Unknown Object (File)
Dec 2 2024, 8:02 AM
Unknown Object (File)
Nov 29 2024, 10:41 PM

Details

Summary

Change cdev_mgtdev_page_free_page to take an iterator, rather than an object and page, so that removing the page from the object radix tree can take advantage of locality with iterators. Define a general-purpose function to free multiple pages, which can be used in several places.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

sys/vm/device_pager.c
267
292

Looking at the callers of cdev_mgtdev_pager_free_pages(), I believe that in all cases the page count is simply the number of resident pages in the object. In that case, I would suggest simply iterating over all pages in the object and freeing them, rather than passing this count.

dougm marked an inline comment as done.

Drop length argument to cdev_mgtdev_pager_free_pages().

This revision is now accepted and ready to land.Nov 21 2024, 10:34 AM