Move rtvals initialization out of the region protected by NFS node
lock. Noted by: alc Reviewed by: alc, markj Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 1 week X-Differential revision: https://reviews.freebsd.org/D11697
This commit is contained in:
parent
ce793a529b
commit
cc2c26223b
@ -306,10 +306,6 @@ ncl_putpages(struct vop_putpages_args *ap)
|
||||
printf("ncl_putpages: called on noncache-able vnode\n");
|
||||
mtx_lock(&np->n_mtx);
|
||||
}
|
||||
|
||||
for (i = 0; i < npages; i++)
|
||||
rtvals[i] = VM_PAGER_ERROR;
|
||||
|
||||
/*
|
||||
* When putting pages, do not extend file past EOF.
|
||||
*/
|
||||
@ -320,6 +316,9 @@ ncl_putpages(struct vop_putpages_args *ap)
|
||||
}
|
||||
mtx_unlock(&np->n_mtx);
|
||||
|
||||
for (i = 0; i < npages; i++)
|
||||
rtvals[i] = VM_PAGER_ERROR;
|
||||
|
||||
VM_CNT_INC(v_vnodeout);
|
||||
VM_CNT_ADD(v_vnodepgsout, count);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user