aboutsummaryrefslogtreecommitdiff
path: root/sys/modules
diff options
context:
space:
mode:
authorDoug Moore <dougm@FreeBSD.org>2023-11-15 09:25:45 +0000
committerMark Johnston <markj@FreeBSD.org>2023-12-04 14:05:55 +0000
commit4be96902ba82364810b86a6a0b3c58065e45e4cd (patch)
tree79b1212395ba77047e8aad89a50b0a32394da6bb /sys/modules
parentad3edd66d15e6af1bf7e393a01f1a126dfa55fff (diff)
vm_phys: fix freelist_contig
vm_phys_find_freelist_contig is called to search a list of max-sized free page blocks and find one that, when joined with adjacent blocks in memory, can satisfy a request for a memory allocation bigger than any single max-sized free page block. In commit fa8a6585c7522b7de6d29802967bd5eba2f2dcf1, I defined this function in order to offer two improvements: 1) reduce the worst-case search time, and 2) allow solutions that include less-than max-sized free page blocks at the front or back of the giant allocation. However, it turns out that this change introduced an error, reported in In Bug 274592. That error concerns failing to check segment boundaries. This change fixes an error in vm_phys_find_freelist_config that resolves that bug. It also abandons improvement 2), because the value of that improvement is small and because preserving it would require more testing than I am able to do. PR: 274592 Reported by: shafaisal.us@gmail.com Reviewed by: alc, markj Tested by: shafaisal.us@gmail.com Fixes: fa8a6585c752 vm_phys: avoid waste in multipage allocation MFC after: 10 days Differential Revision: https://reviews.freebsd.org/D42509 Approved by: so Security: FreeBSD-EN-23:20.vm (cherry picked from commit 2a4897bd4e1bd8430d955abd3cf6675956bb9d61) (cherry picked from commit 210fce73ae0e4106a3aeb1970ffbeb30d0baa6ba)
Diffstat (limited to 'sys/modules')
0 files changed, 0 insertions, 0 deletions