summaryrefslogtreecommitdiffstats
path: root/sys/nlm/nlm_advlock.c
diff options
context:
space:
mode:
authorrmacklem <rmacklem@FreeBSD.org>2011-01-03 20:37:31 +0000
committerrmacklem <rmacklem@FreeBSD.org>2011-01-03 20:37:31 +0000
commit53f27d6094f8d165bcafb24f7a049f6b3cf2a986 (patch)
tree9aed4c3870731f851dbebcf0e78c72a3ef040397 /sys/nlm/nlm_advlock.c
parent75e493953d739c141bef8a454eef4aedb9bf11d9 (diff)
downloadFreeBSD-src-53f27d6094f8d165bcafb24f7a049f6b3cf2a986.zip
FreeBSD-src-53f27d6094f8d165bcafb24f7a049f6b3cf2a986.tar.gz
Fix the nlm so that it no longer depends on the regular
nfs client and, as such, can be loaded for the experimental nfs client without the regular client. Reviewed by: jhb MFC after: 2 weeks
Diffstat (limited to 'sys/nlm/nlm_advlock.c')
-rw-r--r--sys/nlm/nlm_advlock.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/sys/nlm/nlm_advlock.c b/sys/nlm/nlm_advlock.c
index b4edb4d..416cd1d 100644
--- a/sys/nlm/nlm_advlock.c
+++ b/sys/nlm/nlm_advlock.c
@@ -217,20 +217,18 @@ nlm_advlock_internal(struct vnode *vp, void *id, int op, struct flock *fl,
ASSERT_VOP_LOCKED(vp, "nlm_advlock_1");
+ nmp = VFSTONFS(vp->v_mount);
/*
* Push any pending writes to the server and flush our cache
* so that if we are contending with another machine for a
* file, we get whatever they wrote and vice-versa.
*/
if (op == F_SETLK || op == F_UNLCK)
- nfs_vinvalbuf(vp, V_SAVE, td, 1);
+ nmp->nm_vinvalbuf(vp, V_SAVE, td, 1);
- nmp = VFSTONFS(vp->v_mount);
strcpy(servername, nmp->nm_hostname);
- nmp->nm_getinfo(vp, fh.fh_bytes, &fhlen, &ss, &is_v3, &size);
+ nmp->nm_getinfo(vp, fh.fh_bytes, &fhlen, &ss, &is_v3, &size, &timo);
sa = (struct sockaddr *) &ss;
- timo.tv_sec = nmp->nm_timeo / NFS_HZ;
- timo.tv_usec = (nmp->nm_timeo % NFS_HZ) * (1000000 / NFS_HZ);
if (is_v3 != 0)
vers = NLM_VERS4;
else
OpenPOWER on IntegriCloud