vm_page_free_invalid(): Relax the xbusy assertion.
vm_page_assert_xbusied() asserts that the busying thread is the current thread. For some uses of vm_page_free_invalid() (e.g., error handling in vnode_pager_generic_getpages_done()), this condition might not hold. Reported by: Jenkins via trasz Reviewed by: chs, kib Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D25828
This commit is contained in:
parent
58f5de0d8a
commit
782ebde52e
@ -1371,10 +1371,15 @@ vm_page_free_invalid(vm_page_t m)
|
|||||||
|
|
||||||
KASSERT(vm_page_none_valid(m), ("page %p is valid", m));
|
KASSERT(vm_page_none_valid(m), ("page %p is valid", m));
|
||||||
KASSERT(!pmap_page_is_mapped(m), ("page %p is mapped", m));
|
KASSERT(!pmap_page_is_mapped(m), ("page %p is mapped", m));
|
||||||
vm_page_assert_xbusied(m);
|
|
||||||
KASSERT(m->object != NULL, ("page %p has no object", m));
|
KASSERT(m->object != NULL, ("page %p has no object", m));
|
||||||
VM_OBJECT_ASSERT_WLOCKED(m->object);
|
VM_OBJECT_ASSERT_WLOCKED(m->object);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* We may be attempting to free the page as part of the handling for an
|
||||||
|
* I/O error, in which case the page was xbusied by a different thread.
|
||||||
|
*/
|
||||||
|
vm_page_xbusy_claim(m);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If someone has wired this page while the object lock
|
* If someone has wired this page while the object lock
|
||||||
* was not held, then the thread that unwires is responsible
|
* was not held, then the thread that unwires is responsible
|
||||||
|
Loading…
Reference in New Issue
Block a user