diff options
author | attilio <attilio@FreeBSD.org> | 2014-02-21 09:43:34 +0000 |
---|---|---|
committer | attilio <attilio@FreeBSD.org> | 2014-02-21 09:43:34 +0000 |
commit | cf0fa484f90ab986cb54e311aef02cbd8f18401a (patch) | |
tree | 336d1f49febc2c757f1df54ad5c5ce4d0219ce92 /sys/vm/vm_object.c | |
parent | 9f9257101a73a807f44a8b46452822dbab7305b0 (diff) | |
download | FreeBSD-src-cf0fa484f90ab986cb54e311aef02cbd8f18401a.zip FreeBSD-src-cf0fa484f90ab986cb54e311aef02cbd8f18401a.tar.gz |
MFC r261867:
Use the right index to free swapspace after vm_page_rename().
Diffstat (limited to 'sys/vm/vm_object.c')
-rw-r--r-- | sys/vm/vm_object.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/vm/vm_object.c b/sys/vm/vm_object.c index 8683e2f..6fbecc7 100644 --- a/sys/vm/vm_object.c +++ b/sys/vm/vm_object.c @@ -1628,9 +1628,11 @@ vm_object_backing_scan(vm_object_t object, int op) p = TAILQ_FIRST(&backing_object->memq); continue; } + + /* Use the old pindex to free the right page. */ if (backing_object->type == OBJT_SWAP) - swap_pager_freespace(backing_object, p->pindex, - 1); + swap_pager_freespace(backing_object, + new_pindex + backing_offset_index, 1); #if VM_NRESERVLEVEL > 0 /* |