Skip to content

Commit

Permalink
swap_pager: fix assert in seek_data
Browse files Browse the repository at this point in the history
An assertion that an object was write-locked should be instead an
assertion that the object is read locked.

Reported by:	Jenkins
Fixes:	 db08b0b tmpfs_vnops: move swap work to swap_pager
Differential Revision:	https://reviews.freebsd.org/D47278
  • Loading branch information
Doug Moore authored and Doug Moore committed Oct 24, 2024
1 parent a3a88aa commit 02e85d1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sys/vm/swap_pager.c
Original file line number Diff line number Diff line change
Expand Up @@ -2487,7 +2487,7 @@ swap_pager_seek_data(vm_object_t object, vm_pindex_t pindex)
vm_page_t m;
vm_pindex_t swap_index;

VM_OBJECT_ASSERT_WLOCKED(object);
VM_OBJECT_ASSERT_RLOCKED(object);
vm_page_iter_init(&pages, object);
m = vm_page_iter_lookup_ge(&pages, pindex);
if (m != NULL) {
Expand Down

0 comments on commit 02e85d1

Please sign in to comment.