- Extend the scope of two existing vm_object locks to cover
swap_pager_freespace().
This commit is contained in:
parent
55771d518f
commit
20559dc8d8
@ -2144,7 +2144,6 @@ vm_map_delete(vm_map_t map, vm_offset_t start, vm_offset_t end)
|
||||
vm_object_collapse(object);
|
||||
VM_OBJECT_LOCK(object);
|
||||
vm_object_page_remove(object, offidxstart, offidxend, FALSE);
|
||||
VM_OBJECT_UNLOCK(object);
|
||||
if (object->type == OBJT_SWAP) {
|
||||
swap_pager_freespace(object, offidxstart, count);
|
||||
}
|
||||
@ -2152,6 +2151,7 @@ vm_map_delete(vm_map_t map, vm_offset_t start, vm_offset_t end)
|
||||
offidxstart < object->size) {
|
||||
object->size = offidxstart;
|
||||
}
|
||||
VM_OBJECT_UNLOCK(object);
|
||||
}
|
||||
mtx_unlock(&Giant);
|
||||
}
|
||||
|
@ -1797,10 +1797,10 @@ vm_object_coalesce(vm_object_t prev_object, vm_pindex_t prev_pindex,
|
||||
vm_object_page_remove(prev_object,
|
||||
next_pindex,
|
||||
next_pindex + next_size, FALSE);
|
||||
VM_OBJECT_UNLOCK(prev_object);
|
||||
if (prev_object->type == OBJT_SWAP)
|
||||
swap_pager_freespace(prev_object,
|
||||
next_pindex, next_size);
|
||||
VM_OBJECT_UNLOCK(prev_object);
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user