From 591c94d4c67807bb48f559afc01b6fb90384559a Mon Sep 17 00:00:00 2001 From: phk Date: Thu, 26 Aug 1999 14:53:31 +0000 Subject: Simplify the handling of VCHR and VBLK vnodes using the new dev_t: Make the alias list a SLIST. Drop the "fast recycling" optimization of vnodes (including the returning of a prexisting but stale vnode from checkalias). It doesn't buy us anything now that we don't hardlimit vnodes anymore. Rename checkalias2() and checkalias() to addalias() and addaliasu() - which takes dev_t and udev_t arg respectively. Make the revoke syscalls use vcount() instead of VALIASED. Remove VALIASED flag, we don't need it now and it is faster to traverse the much shorter lists than to maintain the flag. vfs_mountedon() can check the dev_t directly, all the vnodes point to the same one. Print the devicename in specfs/vprint(). Remove a couple of stale LFS vnode flags. Remove unimplemented/unused LK_DRAINED; --- sys/nfsclient/nfs_subs.c | 23 ++--------------------- 1 file changed, 2 insertions(+), 21 deletions(-) (limited to 'sys/nfsclient') diff --git a/sys/nfsclient/nfs_subs.c b/sys/nfsclient/nfs_subs.c index 08108a6..9ffb490 100644 --- a/sys/nfsclient/nfs_subs.c +++ b/sys/nfsclient/nfs_subs.c @@ -34,7 +34,7 @@ * SUCH DAMAGE. * * @(#)nfs_subs.c 8.8 (Berkeley) 5/22/95 - * $Id: nfs_subs.c,v 1.79 1999/07/17 18:43:47 phk Exp $ + * $Id: nfs_subs.c,v 1.80 1999/08/08 18:42:55 phk Exp $ */ /* @@ -1311,26 +1311,7 @@ nfs_loadattrcache(vpp, mdp, dposp, vaper) } if (vp->v_type == VCHR || vp->v_type == VBLK) { vp->v_op = spec_nfsv2nodeop_p; - nvp = checkalias(vp, rdev, vp->v_mount); - if (nvp) { - /* - * Discard unneeded vnode, but save its nfsnode. - * Since the nfsnode does not have a lock, its - * vnode lock has to be carried over. - */ - nvp->v_vnlock = vp->v_vnlock; - vp->v_vnlock = NULL; - nvp->v_data = vp->v_data; - vp->v_data = NULL; - vp->v_op = spec_vnodeop_p; - vrele(vp); - vgone(vp); - /* - * Reinitialize aliased node. - */ - np->n_vnode = nvp; - *vpp = vp = nvp; - } + addaliasu(vp, rdev); } np->n_mtime = mtime.tv_sec; } -- cgit v1.1