Page MenuHomeFreeBSD

vm_fault: avoid vm_page_next()
ClosedPublic

Authored by dougm on Jul 27 2024, 5:41 PM.
Tags
None
Referenced Files
Unknown Object (File)
Oct 20 2024, 2:19 AM
Unknown Object (File)
Oct 4 2024, 9:02 PM
Unknown Object (File)
Oct 2 2024, 8:22 AM
Unknown Object (File)
Oct 2 2024, 8:16 AM
Unknown Object (File)
Oct 1 2024, 11:40 AM
Unknown Object (File)
Oct 1 2024, 5:33 AM
Unknown Object (File)
Sep 27 2024, 12:44 AM
Unknown Object (File)
Sep 25 2024, 9:10 AM
Subscribers

Details

Summary

vm_fault calls vm_page_next in two places where it ought to use TAILQ_NEXT and add assertions. The result is that in a NODEBUG kernel, the vm_page_next code does needless pindex calculations, and in a GENERIC kernel it leads either to a failed KASSERT or a null-pointer reference that could be caught more clearly by the KASSERTs I've added.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

dougm requested review of this revision.Jul 27 2024, 5:41 PM
dougm created this revision.
This revision is now accepted and ready to land.Jul 27 2024, 8:59 PM
This revision was automatically updated to reflect the committed changes.