summaryrefslogtreecommitdiff
path: root/sys/nfs/nfs_subs.c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1997-10-06 20:23:17 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1997-10-06 20:23:17 +0000
commit85674180ac0b414993bec634994ea51b28390306 (patch)
tree5ce384dfed739e368b8605fc6db4ed1f26a43609 /sys/nfs/nfs_subs.c
parent44f83f3e77b70fbce9f014e39cf5c97bae700213 (diff)
back out vfs lite2 till after 2.2
Diffstat (limited to 'sys/nfs/nfs_subs.c')
-rw-r--r--sys/nfs/nfs_subs.c24
1 files changed, 15 insertions, 9 deletions
diff --git a/sys/nfs/nfs_subs.c b/sys/nfs/nfs_subs.c
index 1506704ef11..7e6cf33656b 100644
--- a/sys/nfs/nfs_subs.c
+++ b/sys/nfs/nfs_subs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nfs_subs.c,v 1.20 1997/10/06 15:23:43 csapuntz Exp $ */
+/* $OpenBSD: nfs_subs.c,v 1.21 1997/10/06 20:20:49 deraadt Exp $ */
/* $NetBSD: nfs_subs.c,v 1.27.4.3 1996/07/08 20:34:24 jtc Exp $ */
/*
@@ -1144,9 +1144,8 @@ nfs_init()
}
#ifdef NFSCLIENT
-int
-nfs_vfs_init(vfsp)
- struct vfsconf *vfsp;
+void
+nfs_vfs_init()
{
register int i;
@@ -1155,8 +1154,6 @@ nfs_vfs_init(vfsp)
nfs_iodwant[i] = (struct proc *)0;
TAILQ_INIT(&nfs_bufq);
nfs_nhinit(); /* Init the nfsnode table */
-
- return (0);
}
/*
@@ -1250,9 +1247,10 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper)
* Since the nfsnode does not have a lock, its
* vnode lock has to be carried over.
*/
-
+#ifdef Lite2_integrated
nvp->v_vnlock = vp->v_vnlock;
vp->v_vnlock = NULL;
+#endif
nvp->v_data = vp->v_data;
vp->v_data = NULL;
vp->v_op = spec_vnodeop_p;
@@ -1696,7 +1694,9 @@ nfsrv_fhtovp(fhp, lockflag, vpp, cred, slp, nam, rdonlyp, kerbflag)
int *rdonlyp;
int kerbflag;
{
+#ifdef Lite2_integrated
struct proc *p = curproc; /* XXX */
+#endif
register struct mount *mp;
register int i;
struct ucred *credanon;
@@ -1704,8 +1704,11 @@ nfsrv_fhtovp(fhp, lockflag, vpp, cred, slp, nam, rdonlyp, kerbflag)
struct sockaddr_in *saddr;
*vpp = (struct vnode *)0;
+#ifdef Lite2_integrated
mp = vfs_getvfs(&fhp->fh_fsid);
-
+#else
+ mp = getvfs(&fhp->fh_fsid);
+#endif
if (!mp)
return (ESTALE);
error = VFS_FHTOVP(mp, &fhp->fh_fid, nam, vpp, &exflags, &credanon);
@@ -1743,8 +1746,11 @@ nfsrv_fhtovp(fhp, lockflag, vpp, cred, slp, nam, rdonlyp, kerbflag)
else
*rdonlyp = 0;
if (!lockflag)
+#ifdef Lite2_integrated
VOP_UNLOCK(*vpp, 0, p);
-
+#else
+ VOP_UNLOCK(*vpp);
+#endif
return (0);
}