aboutsummaryrefslogtreecommitdiff
path: root/lib/virtual_oss/null/(public-mirror)
diff options
context:
space:
mode:
authorMark Johnston <markj@FreeBSD.org>2025-10-16 23:12:54 +0000
committerMark Johnston <markj@FreeBSD.org>2025-10-16 23:13:34 +0000
commit3b9b64457676561b8de2bec7c94c561bbd807b0c (patch)
treeafa41340b10256649012ab61e9e243ece70be925 /lib/virtual_oss/null/(public-mirror)
parent0050289464fa56ec79e060b8d8378b9ff7145a0e (diff)
vm: Fix iterator usage in vm_thread_stack_create()HEADmain
After commit 7a79d0669761 we no longer hold the VM object lock when initializing or advancing the domainset iterator in vm_thread_stack_create(). We could lift the lock out of vm_thread_stack_back() but that poses complications since we cannot allocate KVA with a VM object lock held. Instead of overridding the object's iterator, just borrow that of the current thread. Kernel stacks are basically always allocated with a DOMAINSET_POLICY_PREFER policy, so it's not very important to maintain a global iterator for round-robin allocation. As a part of this, fix up flag handling: make sure we handle M_NOWAIT/M_WAITOK from the caller. Delete a comment in vm_thread_new() which refers to a non-existent consideration (stack swapping has been removed). I suspect vm_thread_new() can use M_WAITOK but opted not to make that change here. Reported by: olce Reviewed by: olce, alc, kib Fixes: 7a79d0669761 ("vm: improve kstack_object pindex calculation to avoid pindex holes") MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D52982
Diffstat (limited to 'lib/virtual_oss/null/(public-mirror)')
0 files changed, 0 insertions, 0 deletions