Deleted Added
full compact
66c66
< __FBSDID("$FreeBSD: stable/11/sys/vm/vm_object.c 323537 2017-09-13 11:19:04Z kib $");
---
> __FBSDID("$FreeBSD: stable/11/sys/vm/vm_object.c 323638 2017-09-16 13:49:26Z kib $");
1912a1913
> struct mtx *mtx;
1922a1924
> mtx = NULL;
1939c1941
< vm_page_lock(p);
---
> vm_page_change_lock(p, &mtx);
1953c1955
< goto next;
---
> continue;
1967c1969
< goto next;
---
> continue;
1972,1973d1973
< next:
< vm_page_unlock(p);
1974a1975,1976
> if (mtx != NULL)
> mtx_unlock(mtx);
1997c1999
< struct mtx *mtx, *new_mtx;
---
> struct mtx *mtx;
2014,2024c2016
<
< /*
< * Avoid releasing and reacquiring the same page lock.
< */
< new_mtx = vm_page_lockptr(p);
< if (mtx != new_mtx) {
< if (mtx != NULL)
< mtx_unlock(mtx);
< mtx = new_mtx;
< mtx_lock(mtx);
< }
---
> vm_page_change_lock(p, &mtx);