From 597aea932ac3ac7477bdb343a994fe7948ec9582 Mon Sep 17 00:00:00 2001 From: David Rhodus Date: Sat, 24 Apr 2004 04:32:06 +0000 Subject: [PATCH] Remove the VREF() macro and uses of it. Remove uses of 0x20 before ^I inside vnode.h --- sys/emulation/43bsd/43bsd_file.c | 4 +- .../linux/i386/linprocfs/linprocfs_vnops.c | 4 +- sys/emulation/linux/linux_getcwd.c | 8 +- sys/emulation/svr4/svr4_misc.c | 4 +- sys/kern/init_main.c | 6 +- sys/kern/kern_descrip.c | 14 +-- sys/kern/kern_exec.c | 4 +- sys/kern/kern_fork.c | 6 +- sys/kern/kern_ktrace.c | 14 +-- sys/kern/vfs_cache.c | 4 +- sys/kern/vfs_lookup.c | 22 ++--- sys/kern/vfs_syscalls.c | 18 ++-- sys/kern/vfs_vnops.c | 4 +- sys/sys/vnode.h | 94 +++++++++---------- sys/vfs/fdesc/fdesc_vfsops.c | 4 +- sys/vfs/fdesc/fdesc_vnops.c | 4 +- sys/vfs/gnu/ext2fs/ext2_lookup.c | 6 +- sys/vfs/gnu/ext2fs/ext2_vfsops.c | 4 +- sys/vfs/gnu/ext2fs/ext2_vnops.c | 6 +- sys/vfs/hpfs/hpfs_vfsops.c | 4 +- sys/vfs/hpfs/hpfs_vnops.c | 6 +- sys/vfs/isofs/cd9660/cd9660_lookup.c | 4 +- sys/vfs/isofs/cd9660/cd9660_vfsops.c | 4 +- sys/vfs/msdosfs/msdosfs_denode.c | 6 +- sys/vfs/msdosfs/msdosfs_lookup.c | 6 +- sys/vfs/nfs/nfs_serv.c | 4 +- sys/vfs/nfs/nfs_subs.c | 6 +- sys/vfs/nfs/nfs_vfsops.c | 4 +- sys/vfs/nfs/nfs_vnops.c | 12 +-- sys/vfs/ntfs/ntfs_subr.c | 6 +- sys/vfs/ntfs/ntfs_vfsops.c | 4 +- sys/vfs/ntfs/ntfs_vnops.c | 4 +- sys/vfs/nullfs/null.h | 4 +- sys/vfs/nullfs/null_subr.c | 12 +-- sys/vfs/nullfs/null_vfsops.c | 4 +- sys/vfs/nullfs/null_vnops.c | 8 +- sys/vfs/nwfs/nwfs_vnops.c | 4 +- sys/vfs/portal/portal_vfsops.c | 4 +- sys/vfs/portal/portal_vnops.c | 4 +- sys/vfs/procfs/procfs_vnops.c | 4 +- sys/vfs/smbfs/smbfs_vnops.c | 4 +- sys/vfs/udf/udf_vfsops.c | 4 +- sys/vfs/ufs/ffs_vfsops.c | 6 +- sys/vfs/ufs/ufs_lookup.c | 6 +- sys/vfs/ufs/ufs_vnops.c | 6 +- sys/vfs/umapfs/umap.h | 4 +- sys/vfs/umapfs/umap_subr.c | 12 +-- sys/vfs/umapfs/umap_vfsops.c | 4 +- sys/vfs/umapfs/umap_vnops.c | 6 +- sys/vfs/union/union_subr.c | 16 ++-- sys/vfs/union/union_vfsops.c | 8 +- sys/vfs/union/union_vnops.c | 18 ++-- 52 files changed, 217 insertions(+), 221 deletions(-) diff --git a/sys/emulation/43bsd/43bsd_file.c b/sys/emulation/43bsd/43bsd_file.c index 002f3e529a..747d963f53 100644 --- a/sys/emulation/43bsd/43bsd_file.c +++ b/sys/emulation/43bsd/43bsd_file.c @@ -37,7 +37,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $DragonFly: src/sys/emulation/43bsd/43bsd_file.c,v 1.4 2004/03/01 06:33:15 dillon Exp $ + * $DragonFly: src/sys/emulation/43bsd/43bsd_file.c,v 1.5 2004/04/24 04:32:02 drhodus Exp $ * from: DragonFly kern/vfs_syscalls.c,v 1.20 * * These syscalls used to live in kern/vfs_syscalls.c. They are modified @@ -215,7 +215,7 @@ unionread: (vp->v_mount->mnt_flag & MNT_UNION)) { struct vnode *tvp = vp; vp = vp->v_mount->mnt_vnodecovered; - VREF(vp); + vref(vp); fp->f_data = (caddr_t) vp; fp->f_offset = 0; vrele(tvp); diff --git a/sys/emulation/linux/i386/linprocfs/linprocfs_vnops.c b/sys/emulation/linux/i386/linprocfs/linprocfs_vnops.c index e5947cf671..fcfe1b61e8 100644 --- a/sys/emulation/linux/i386/linprocfs/linprocfs_vnops.c +++ b/sys/emulation/linux/i386/linprocfs/linprocfs_vnops.c @@ -39,7 +39,7 @@ * @(#)procfs_vnops.c 8.18 (Berkeley) 5/21/95 * * $FreeBSD: src/sys/i386/linux/linprocfs/linprocfs_vnops.c,v 1.3.2.5 2001/08/12 14:29:19 rwatson Exp $ - * $DragonFly: src/sys/emulation/linux/i386/linprocfs/linprocfs_vnops.c,v 1.10 2004/03/01 06:33:15 dillon Exp $ + * $DragonFly: src/sys/emulation/linux/i386/linprocfs/linprocfs_vnops.c,v 1.11 2004/04/24 04:32:03 drhodus Exp $ */ /* @@ -668,7 +668,7 @@ linprocfs_lookup(ap) if (cnp->cn_namelen == 1 && *pname == '.') { *vpp = dvp; - VREF(dvp); + vref(dvp); /* vn_lock(dvp, NULL, LK_EXCLUSIVE | LK_RETRY, curp); */ return (0); } diff --git a/sys/emulation/linux/linux_getcwd.c b/sys/emulation/linux/linux_getcwd.c index 102ed09725..034abdf374 100644 --- a/sys/emulation/linux/linux_getcwd.c +++ b/sys/emulation/linux/linux_getcwd.c @@ -1,5 +1,5 @@ /* $FreeBSD: src/sys/compat/linux/linux_getcwd.c,v 1.2.2.3 2001/11/05 19:08:22 marcel Exp $ */ -/* $DragonFly: src/sys/emulation/linux/linux_getcwd.c,v 1.14 2004/03/01 06:33:15 dillon Exp $ */ +/* $DragonFly: src/sys/emulation/linux/linux_getcwd.c,v 1.15 2004/04/24 04:32:02 drhodus Exp $ */ /* $OpenBSD: linux_getcwd.c,v 1.2 2001/05/16 12:50:21 ho Exp $ */ /* $NetBSD: vfs_getcwd.c,v 1.3.2.3 1999/07/11 10:24:09 sommerfeld Exp $ */ @@ -303,8 +303,8 @@ linux_getcwd_common (lvp, rvp, bpp, bufp, limit, flags, td) rvp = rootvnode; } - VREF(rvp); - VREF(lvp); + vref(rvp); + vref(lvp); /* * Error handling invariant: @@ -368,7 +368,7 @@ linux_getcwd_common (lvp, rvp, bpp, bufp, limit, flags, td) error = ENOENT; goto out; } - VREF(lvp); + vref(lvp); error = vn_lock(lvp, NULL, LK_EXCLUSIVE | LK_RETRY, td); if (error != 0) { vrele(lvp); diff --git a/sys/emulation/svr4/svr4_misc.c b/sys/emulation/svr4/svr4_misc.c index 04e6fd1779..31cc7cce70 100644 --- a/sys/emulation/svr4/svr4_misc.c +++ b/sys/emulation/svr4/svr4_misc.c @@ -26,7 +26,7 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * * $FreeBSD: src/sys/svr4/svr4_misc.c,v 1.13.2.7 2003/01/14 21:33:58 dillon Exp $ - * $DragonFly: src/sys/emulation/svr4/Attic/svr4_misc.c,v 1.21 2004/03/01 06:33:15 dillon Exp $ + * $DragonFly: src/sys/emulation/svr4/Attic/svr4_misc.c,v 1.22 2004/04/24 04:32:03 drhodus Exp $ */ /* @@ -617,7 +617,7 @@ svr4_sys_fchroot(struct svr4_sys_fchroot_args *uap) VOP_UNLOCK(vp, NULL, 0, td); if (error) return error; - VREF(vp); + vref(vp); if (fdp->fd_rdir != NULL) vrele(fdp->fd_rdir); fdp->fd_rdir = vp; diff --git a/sys/kern/init_main.c b/sys/kern/init_main.c index 03f4448373..165a790084 100644 --- a/sys/kern/init_main.c +++ b/sys/kern/init_main.c @@ -40,7 +40,7 @@ * * @(#)init_main.c 8.9 (Berkeley) 1/21/94 * $FreeBSD: src/sys/kern/init_main.c,v 1.134.2.8 2003/06/06 20:21:32 tegge Exp $ - * $DragonFly: src/sys/kern/init_main.c,v 1.30 2004/04/01 17:40:57 dillon Exp $ + * $DragonFly: src/sys/kern/init_main.c,v 1.31 2004/04/24 04:32:03 drhodus Exp $ */ #include "opt_init_path.h" @@ -461,9 +461,9 @@ start_init(void *dummy) if (VFS_ROOT(TAILQ_FIRST(&mountlist), &rootvnode)) panic("cannot find root vnode"); p->p_fd->fd_cdir = rootvnode; - VREF(p->p_fd->fd_cdir); + vref(p->p_fd->fd_cdir); p->p_fd->fd_rdir = rootvnode; - VREF(p->p_fd->fd_rdir); + vref(p->p_fd->fd_rdir); vfs_cache_setroot(rootvnode); VOP_UNLOCK(rootvnode, NULL, 0, curthread); diff --git a/sys/kern/kern_descrip.c b/sys/kern/kern_descrip.c index b29121547b..df726e748a 100644 --- a/sys/kern/kern_descrip.c +++ b/sys/kern/kern_descrip.c @@ -37,7 +37,7 @@ * * @(#)kern_descrip.c 8.6 (Berkeley) 4/19/94 * $FreeBSD: src/sys/kern/kern_descrip.c,v 1.81.2.19 2004/02/28 00:43:31 tegge Exp $ - * $DragonFly: src/sys/kern/kern_descrip.c,v 1.21 2004/04/21 06:09:52 dillon Exp $ + * $DragonFly: src/sys/kern/kern_descrip.c,v 1.22 2004/04/24 04:32:03 drhodus Exp $ */ #include "opt_compat.h" @@ -981,13 +981,13 @@ fdinit(p) bzero(newfdp, sizeof(struct filedesc0)); newfdp->fd_fd.fd_cdir = fdp->fd_cdir; if (newfdp->fd_fd.fd_cdir) - VREF(newfdp->fd_fd.fd_cdir); + vref(newfdp->fd_fd.fd_cdir); newfdp->fd_fd.fd_rdir = fdp->fd_rdir; if (newfdp->fd_fd.fd_rdir) - VREF(newfdp->fd_fd.fd_rdir); + vref(newfdp->fd_fd.fd_rdir); newfdp->fd_fd.fd_jdir = fdp->fd_jdir; if (newfdp->fd_fd.fd_jdir) - VREF(newfdp->fd_fd.fd_jdir); + vref(newfdp->fd_fd.fd_jdir); /* Create the file descriptor table. */ newfdp->fd_fd.fd_refcnt = 1; @@ -1030,11 +1030,11 @@ fdcopy(p) M_FILEDESC, M_WAITOK); bcopy(fdp, newfdp, sizeof(struct filedesc)); if (newfdp->fd_cdir) - VREF(newfdp->fd_cdir); + vref(newfdp->fd_cdir); if (newfdp->fd_rdir) - VREF(newfdp->fd_rdir); + vref(newfdp->fd_rdir); if (newfdp->fd_jdir) - VREF(newfdp->fd_jdir); + vref(newfdp->fd_jdir); newfdp->fd_refcnt = 1; /* diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c index 8c39b3e429..251a5faf73 100644 --- a/sys/kern/kern_exec.c +++ b/sys/kern/kern_exec.c @@ -24,7 +24,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/kern/kern_exec.c,v 1.107.2.15 2002/07/30 15:40:46 nectar Exp $ - * $DragonFly: src/sys/kern/kern_exec.c,v 1.24 2004/04/24 04:09:21 drhodus Exp $ + * $DragonFly: src/sys/kern/kern_exec.c,v 1.25 2004/04/24 04:32:03 drhodus Exp $ */ #include @@ -383,7 +383,7 @@ interpret: */ if (p->p_textvp) /* release old reference */ vrele(p->p_textvp); - VREF(ndp->ni_vp); + vref(ndp->ni_vp); p->p_textvp = ndp->ni_vp; /* diff --git a/sys/kern/kern_fork.c b/sys/kern/kern_fork.c index 3a9b9b16e7..e3d78813c4 100644 --- a/sys/kern/kern_fork.c +++ b/sys/kern/kern_fork.c @@ -37,7 +37,7 @@ * * @(#)kern_fork.c 8.6 (Berkeley) 4/8/94 * $FreeBSD: src/sys/kern/kern_fork.c,v 1.72.2.14 2003/06/26 04:15:10 silby Exp $ - * $DragonFly: src/sys/kern/kern_fork.c,v 1.23 2004/04/12 17:49:27 dillon Exp $ + * $DragonFly: src/sys/kern/kern_fork.c,v 1.24 2004/04/24 04:32:03 drhodus Exp $ */ #include "opt_ktrace.h" @@ -412,7 +412,7 @@ again: /* bump references to the text vnode (for procfs) */ p2->p_textvp = p1->p_textvp; if (p2->p_textvp) - VREF(p2->p_textvp); + vref(p2->p_textvp); if (flags & RFCFDG) { p2->p_fd = fdinit(p1); @@ -493,7 +493,7 @@ again: if ((p1->p_traceflag & KTRFAC_INHERIT) && p2->p_tracep == NULL) { p2->p_traceflag = p1->p_traceflag; if ((p2->p_tracep = p1->p_tracep) != NULL) - VREF(p2->p_tracep); + vref(p2->p_tracep); } #endif diff --git a/sys/kern/kern_ktrace.c b/sys/kern/kern_ktrace.c index f8138b938f..dda0b2e9cb 100644 --- a/sys/kern/kern_ktrace.c +++ b/sys/kern/kern_ktrace.c @@ -32,7 +32,7 @@ * * @(#)kern_ktrace.c 8.2 (Berkeley) 9/23/93 * $FreeBSD: src/sys/kern/kern_ktrace.c,v 1.35.2.6 2002/07/05 22:36:38 darrenr Exp $ - * $DragonFly: src/sys/kern/kern_ktrace.c,v 1.13 2004/03/01 06:33:17 dillon Exp $ + * $DragonFly: src/sys/kern/kern_ktrace.c,v 1.14 2004/04/24 04:32:03 drhodus Exp $ */ #include "opt_ktrace.h" @@ -135,7 +135,7 @@ ktrnamei(struct vnode *vp, char *path) * don't let vp get ripped out from under us */ if (vp) - VREF(vp); + vref(vp); p->p_traceflag |= KTRFAC_ACTIVE; kth = ktrgetheader(KTR_NAMEI); kth->ktr_len = strlen(path); @@ -161,7 +161,7 @@ ktrgenio(struct vnode *vp, int fd, enum uio_rw rw, struct uio *uio, int error) * don't let p_tracep get ripped out from under us */ if (vp) - VREF(vp); + vref(vp); p->p_traceflag |= KTRFAC_ACTIVE; kth = ktrgetheader(KTR_GENIO); ktg.ktr_fd = fd; @@ -189,7 +189,7 @@ ktrpsig(struct vnode *vp, int sig, sig_t action, sigset_t *mask, int code) * don't let vp get ripped out from under us */ if (vp) - VREF(vp); + vref(vp); p->p_traceflag |= KTRFAC_ACTIVE; kth = ktrgetheader(KTR_PSIG); kp.signo = (char)sig; @@ -217,7 +217,7 @@ ktrcsw(struct vnode *vp, int out, int user) * don't let vp get ripped out from under us */ if (vp) - VREF(vp); + vref(vp); p->p_traceflag |= KTRFAC_ACTIVE; kth = ktrgetheader(KTR_CSW); kc.out = out; @@ -368,7 +368,7 @@ utrace(struct utrace_args *uap) * writing. */ if ((vp = p->p_tracep) != NULL) - VREF(vp); + vref(vp); kth = ktrgetheader(KTR_USER); MALLOC(cp, caddr_t, uap->len, M_KTRACE, M_WAITOK); if (!copyin(uap->addr, cp, uap->len)) { @@ -402,7 +402,7 @@ ktrops(struct proc *curp, struct proc *p, int ops, int facs, struct vnode *vp) /* * if trace file already in use, relinquish */ - VREF(vp); + vref(vp); while ((vtmp = p->p_tracep) != NULL) { p->p_tracep = NULL; vrele(vtmp); diff --git a/sys/kern/vfs_cache.c b/sys/kern/vfs_cache.c index a519e521a9..92444901ed 100644 --- a/sys/kern/vfs_cache.c +++ b/sys/kern/vfs_cache.c @@ -37,7 +37,7 @@ * * @(#)vfs_cache.c 8.5 (Berkeley) 3/22/95 * $FreeBSD: src/sys/kern/vfs_cache.c,v 1.42.2.6 2001/10/05 20:07:03 dillon Exp $ - * $DragonFly: src/sys/kern/vfs_cache.c,v 1.16 2004/04/08 22:00:41 dillon Exp $ + * $DragonFly: src/sys/kern/vfs_cache.c,v 1.17 2004/04/24 04:32:03 drhodus Exp $ */ #include @@ -902,7 +902,7 @@ vfs_cache_lookup(struct vop_lookup_args *ap) vpid = vp->v_id; cnp->cn_flags &= ~CNP_PDIRUNLOCK; if (dvp == vp) { /* lookup on "." */ - VREF(vp); + vref(vp); error = 0; } else if (flags & CNP_ISDOTDOT) { VOP_UNLOCK(dvp, NULL, 0, td); diff --git a/sys/kern/vfs_lookup.c b/sys/kern/vfs_lookup.c index 17bb8b693b..b39eb28dfc 100644 --- a/sys/kern/vfs_lookup.c +++ b/sys/kern/vfs_lookup.c @@ -37,7 +37,7 @@ * * @(#)vfs_lookup.c 8.4 (Berkeley) 2/16/94 * $FreeBSD: src/sys/kern/vfs_lookup.c,v 1.38.2.3 2001/08/31 19:36:49 dillon Exp $ - * $DragonFly: src/sys/kern/vfs_lookup.c,v 1.10 2004/03/01 06:33:17 dillon Exp $ + * $DragonFly: src/sys/kern/vfs_lookup.c,v 1.11 2004/04/24 04:32:03 drhodus Exp $ */ #include "opt_ktrace.h" @@ -142,7 +142,7 @@ namei(struct nameidata *ndp) ndp->ni_topdir = fdp->fd_jdir; dp = fdp->fd_cdir; - VREF(dp); + vref(dp); for (;;) { /* * Check if root directory should replace current directory. @@ -156,7 +156,7 @@ namei(struct nameidata *ndp) ndp->ni_pathlen--; } dp = ndp->ni_rootdir; - VREF(dp); + vref(dp); } ndp->ni_startdir = dp; error = lookup(ndp); @@ -390,7 +390,7 @@ dirloop: } if (wantparent) { ndp->ni_dvp = dp; - VREF(dp); + vref(dp); } ndp->ni_vp = dp; if (!(cnp->cn_flags & (CNP_LOCKPARENT | CNP_LOCKLEAF))) @@ -420,7 +420,7 @@ dirloop: dp == rootvnode) { ndp->ni_dvp = dp; ndp->ni_vp = dp; - VREF(dp); + vref(dp); goto nextname; } if ((dp->v_flag & VROOT) == 0 || @@ -433,7 +433,7 @@ dirloop: tdp = dp; dp = dp->v_mount->mnt_vnodecovered; vput(tdp); - VREF(dp); + vref(dp); vn_lock(dp, NULL, LK_EXCLUSIVE | LK_RETRY, td); } } @@ -460,7 +460,7 @@ unionlookup: vrele(tdp); else vput(tdp); - VREF(dp); + vref(dp); vn_lock(dp, NULL, LK_EXCLUSIVE | LK_RETRY, td); goto unionlookup; } @@ -487,7 +487,7 @@ unionlookup: */ if (cnp->cn_flags & CNP_SAVESTART) { ndp->ni_startdir = ndp->ni_dvp; - VREF(ndp->ni_startdir); + vref(ndp->ni_startdir); } return (0); } @@ -584,7 +584,7 @@ nextname: } if (cnp->cn_flags & CNP_SAVESTART) { ndp->ni_startdir = ndp->ni_dvp; - VREF(ndp->ni_startdir); + vref(ndp->ni_startdir); } if (!wantparent) vrele(ndp->ni_dvp); @@ -700,7 +700,7 @@ relookup(dvp, vpp, cnp) } /* ASSERT(dvp == ndp->ni_startdir) */ if (cnp->cn_flags & CNP_SAVESTART) - VREF(dvp); + vref(dvp); /* * We return with ni_vp NULL to indicate that the entry * doesn't currently exist, leaving a pointer to the @@ -726,7 +726,7 @@ relookup(dvp, vpp, cnp) } /* ASSERT(dvp == ndp->ni_startdir) */ if (cnp->cn_flags & CNP_SAVESTART) - VREF(dvp); + vref(dvp); if (!wantparent) vrele(dvp); diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 2e73c2b136..fd02443b8f 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -37,7 +37,7 @@ * * @(#)vfs_syscalls.c 8.13 (Berkeley) 4/15/94 * $FreeBSD: src/sys/kern/vfs_syscalls.c,v 1.151.2.18 2003/04/04 20:35:58 tegge Exp $ - * $DragonFly: src/sys/kern/vfs_syscalls.c,v 1.32 2004/04/21 04:49:00 hmp Exp $ + * $DragonFly: src/sys/kern/vfs_syscalls.c,v 1.33 2004/04/24 04:32:03 drhodus Exp $ */ #include @@ -354,18 +354,18 @@ checkdirs(struct vnode *olddp) fdp = p->p_fd; if (fdp->fd_cdir == olddp) { vrele(fdp->fd_cdir); - VREF(newdp); + vref(newdp); fdp->fd_cdir = newdp; } if (fdp->fd_rdir == olddp) { vrele(fdp->fd_rdir); - VREF(newdp); + vref(newdp); fdp->fd_rdir = newdp; } } if (rootvnode == olddp) { vrele(rootvnode); - VREF(newdp); + vref(newdp); rootvnode = newdp; vfs_cache_setroot(rootvnode); } @@ -764,7 +764,7 @@ fchdir(struct fchdir_args *uap) if ((error = getvnode(fdp, SCARG(uap, fd), &fp)) != 0) return (error); vp = (struct vnode *)fp->f_data; - VREF(vp); + vref(vp); vn_lock(vp, NULL, LK_EXCLUSIVE | LK_RETRY, td); if (vp->v_type != VDIR) error = ENOTDIR; @@ -803,7 +803,7 @@ kern_chdir(struct nameidata *nd) if ((error = checkvp_chdir(nd->ni_vp, td)) == 0) { vrele(fdp->fd_cdir); fdp->fd_cdir = nd->ni_vp; - VREF(fdp->fd_cdir); + vref(fdp->fd_cdir); } NDFREE(nd, ~(NDF_NO_FREE_PNBUF | NDF_NO_VP_PUT)); return (error); @@ -903,10 +903,10 @@ kern_chroot(struct vnode *vp) if ((error = checkvp_chdir(vp, td)) == 0) { vrele(fdp->fd_rdir); fdp->fd_rdir = vp; - VREF(fdp->fd_rdir); + vref(fdp->fd_rdir); if (fdp->fd_jdir == NULL) { fdp->fd_jdir = vp; - VREF(fdp->fd_jdir); + vref(fdp->fd_jdir); } } return (error); @@ -2630,7 +2630,7 @@ unionread: (vp->v_mount->mnt_flag & MNT_UNION)) { struct vnode *tvp = vp; vp = vp->v_mount->mnt_vnodecovered; - VREF(vp); + vref(vp); fp->f_data = (caddr_t) vp; fp->f_offset = 0; vrele(tvp); diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c index 92a448edf0..1f14a8a35b 100644 --- a/sys/kern/vfs_vnops.c +++ b/sys/kern/vfs_vnops.c @@ -37,7 +37,7 @@ * * @(#)vfs_vnops.c 8.2 (Berkeley) 1/21/94 * $FreeBSD: src/sys/kern/vfs_vnops.c,v 1.87.2.13 2002/12/29 18:19:53 dillon Exp $ - * $DragonFly: src/sys/kern/vfs_vnops.c,v 1.17 2004/03/29 15:21:42 drhodus Exp $ + * $DragonFly: src/sys/kern/vfs_vnops.c,v 1.18 2004/04/24 04:32:03 drhodus Exp $ */ #include @@ -615,7 +615,7 @@ vn_ioctl(struct file *fp, u_long com, caddr_t data, struct thread *td) vrele(sess->s_ttyvp); sess->s_ttyvp = vp; - VREF(vp); + vref(vp); } return (error); } diff --git a/sys/sys/vnode.h b/sys/sys/vnode.h index f27e4acf1e..179b935ad7 100644 --- a/sys/sys/vnode.h +++ b/sys/sys/vnode.h @@ -32,7 +32,7 @@ * * @(#)vnode.h 8.7 (Berkeley) 2/4/94 * $FreeBSD: src/sys/sys/vnode.h,v 1.111.2.19 2002/12/29 18:19:53 dillon Exp $ - * $DragonFly: src/sys/sys/vnode.h,v 1.14 2004/04/08 17:56:46 dillon Exp $ + * $DragonFly: src/sys/sys/vnode.h,v 1.15 2004/04/24 04:32:03 drhodus Exp $ */ #ifndef _SYS_VNODE_H_ @@ -123,7 +123,7 @@ struct vnode { lwkt_token_t v_interlock; /* lock on usecount and flag */ struct lock *v_vnlock; /* used for non-locking fs's */ enum vtagtype v_tag; /* type of underlying data */ - void *v_data; /* private data for fs */ + void *v_data; /* private data for fs */ struct namecache_list v_namecache; /* associated nc entries */ struct { struct lwkt_token vpi_token; /* lock to protect below */ @@ -172,8 +172,8 @@ struct vnode { #define VINFREE 0x100000 /* This vnode is in the midst of being freed */ #define VONWORKLST 0x200000 /* On syncer work-list */ #define VMOUNT 0x400000 /* Mount in progress */ -#define VOBJDIRTY 0x800000 /* object might be dirty */ -#define VPLACEMARKER 0x1000000 /* dummy vnode placemarker */ +#define VOBJDIRTY 0x800000 /* object might be dirty */ +#define VPLACEMARKER 0x1000000 /* dummy vnode placemarker */ /* * Vnode attributes. A field value of VNOVAL represents a field whose value @@ -219,12 +219,12 @@ struct vattr { #define IO_VMIO 0x0020 /* data already in VMIO space */ #define IO_INVAL 0x0040 /* invalidate after I/O */ #define IO_ASYNC 0x0080 /* bawrite rather then bdwrite */ -#define IO_DIRECT 0x0100 /* attempt to bypass buffer cache */ -#define IO_NOWDRAIN 0x0200 /* do not block on wdrain */ -#define IO_CORE 0x0400 /* I/O is part of core dump */ +#define IO_DIRECT 0x0100 /* attempt to bypass buffer cache */ +#define IO_NOWDRAIN 0x0200 /* do not block on wdrain */ +#define IO_CORE 0x0400 /* I/O is part of core dump */ -#define IO_SEQMAX 0x7F /* seq heuristic max value */ -#define IO_SEQSHIFT 16 /* seq heuristic in upper 16 bits */ +#define IO_SEQMAX 0x7F /* seq heuristic max value */ +#define IO_SEQSHIFT 16 /* seq heuristic in upper 16 bits */ /* * Modes. Some values same as Ixxx entries from inode.h for now. @@ -244,7 +244,7 @@ struct vattr { /* * LK_TIMELOCK timeout for vnode locks (used mainly by the pageout daemon) */ -#define VLKTIMEOUT (hz / 20 + 1) +#define VLKTIMEOUT (hz / 20 + 1) #ifdef _KERNEL @@ -256,11 +256,11 @@ MALLOC_DECLARE(M_VNODE); * Convert between vnode types and inode formats (since POSIX.1 * defines mode word of stat structure in terms of inode formats). */ -extern enum vtype iftovt_tab[]; -extern int vttoif_tab[]; -#define IFTOVT(mode) (iftovt_tab[((mode) & S_IFMT) >> 12]) -#define VTTOIF(indx) (vttoif_tab[(int)(indx)]) -#define MAKEIMODE(indx, mode) (int)(VTTOIF(indx) | (mode)) +extern enum vtype iftovt_tab[]; +extern int vttoif_tab[]; +#define IFTOVT(mode) (iftovt_tab[((mode) & S_IFMT) >> 12]) +#define VTTOIF(indx) (vttoif_tab[(int)(indx)]) +#define MAKEIMODE(indx, mode) (int)(VTTOIF(indx) | (mode)) /* * Flags to various vnode functions. @@ -272,9 +272,6 @@ extern int vttoif_tab[]; #define V_SAVE 0x0001 /* vinvalbuf: sync file first */ #define REVOKEALL 0x0001 /* vop_revoke: revoke all aliases */ -#define VREF(vp) vref(vp) - - #ifdef DIAGNOSTIC #define VATTR_NULL(vap) vattr_null(vap) #else @@ -315,7 +312,6 @@ extern void (*lease_updatetime) (int deltat); #endif /* _KERNEL */ - /* * Mods for extensibility. */ @@ -323,14 +319,14 @@ extern void (*lease_updatetime) (int deltat); /* * Flags for vdesc_flags: */ -#define VDESC_MAX_VPS 16 +#define VDESC_MAX_VPS 16 /* Low order 16 flag bits are reserved for willrele flags for vp arguments. */ -#define VDESC_VP0_WILLRELE 0x0001 -#define VDESC_VP1_WILLRELE 0x0002 -#define VDESC_VP2_WILLRELE 0x0004 -#define VDESC_VP3_WILLRELE 0x0008 -#define VDESC_NOMAP_VPP 0x0100 -#define VDESC_VPP_WILLRELE 0x0200 +#define VDESC_VP0_WILLRELE 0x0001 +#define VDESC_VP1_WILLRELE 0x0002 +#define VDESC_VP2_WILLRELE 0x0004 +#define VDESC_VP3_WILLRELE 0x0008 +#define VDESC_NOMAP_VPP 0x0100 +#define VDESC_VPP_WILLRELE 0x0200 /* * VDESC_NO_OFFSET is used to identify the end of the offset list @@ -383,11 +379,11 @@ extern struct lwkt_token mntvnode_token; * Crays, so if you decide to port this to such a serious machine, * you might want to consult Intrinsic.h's XtOffset{,Of,To}. */ -#define VOPARG_OFFSET(p_type,field) \ +#define VOPARG_OFFSET(p_type,field) \ ((int) (((char *) (&(((p_type)NULL)->field))) - ((char *) NULL))) -#define VOPARG_OFFSETOF(s_type,field) \ +#define VOPARG_OFFSETOF(s_type,field) \ VOPARG_OFFSET(s_type*,field) -#define VOPARG_OFFSETTO(S_TYPE,S_OFFSET,STRUCT_P) \ +#define VOPARG_OFFSETTO(S_TYPE,S_OFFSET,STRUCT_P) \ ((S_TYPE)(((char*)(STRUCT_P))+(S_OFFSET))) @@ -434,8 +430,8 @@ struct vop_generic_args { || (vp)->v_tag == VT_ISOFS \ || (vp)->v_tag == VT_MSDOSFS) -#define ASSERT_VOP_LOCKED(vp, str) assert_vop_locked(vp, str) -#define ASSERT_VOP_UNLOCKED(vp, str) assert_vop_unlocked(vp, str); +#define ASSERT_VOP_LOCKED(vp, str) assert_vop_locked(vp, str) +#define ASSERT_VOP_UNLOCKED(vp, str) assert_vop_unlocked(vp, str); #define ASSERT_VOP_ELOCKED(vp, str) \ do { \ @@ -472,8 +468,8 @@ void assert_vop_unlocked(struct vnode *vp, const char *str); #else -#define ASSERT_VOP_LOCKED(vp, str) -#define ASSERT_VOP_UNLOCKED(vp, str) +#define ASSERT_VOP_LOCKED(vp, str) +#define ASSERT_VOP_UNLOCKED(vp, str) #endif /* DEBUG_VFS_LOCKS */ @@ -482,14 +478,14 @@ void assert_vop_unlocked(struct vnode *vp, const char *str); * vclean changes the ops vector and then wants to call ops with the old * vector. */ -#define VOCALL(OPSV,OFF,AP) (( *((OPSV)[(OFF)])) (AP)) +#define VOCALL(OPSV,OFF,AP) (( *((OPSV)[(OFF)])) (AP)) /* * This call works for vnodes in the kernel. */ -#define VCALL(VP,OFF,AP) VOCALL((VP)->v_op,(OFF),(AP)) -#define VDESC(OP) (& __CONCAT(OP,_desc)) -#define VOFFSET(OP) (VDESC(OP)->vdesc_offset) +#define VCALL(VP,OFF,AP) VOCALL((VP)->v_op,(OFF),(AP)) +#define VDESC(OP) (& __CONCAT(OP,_desc)) +#define VOFFSET(OP) (VDESC(OP)->vdesc_offset) /* * VMIO support inline @@ -534,13 +530,13 @@ void addaliasu (struct vnode *vp, udev_t nvp_rdev); int bdevvp (dev_t dev, struct vnode **vpp); void cvtstat (struct stat *st, struct ostat *ost); void cvtnstat (struct stat *sb, struct nstat *nsb); -int getnewvnode (enum vtagtype tag, +int getnewvnode (enum vtagtype tag, struct mount *mp, vop_t **vops, struct vnode **vpp); int lease_check (struct vop_lease_args *ap); int spec_vnoperate (struct vop_generic_args *); int speedup_syncer (void); -void vattr_null (struct vattr *vap); -int vcount (struct vnode *vp); +void vattr_null (struct vattr *vap); +int vcount (struct vnode *vp); void vdrop (struct vnode *); int vfinddev (dev_t dev, enum vtype type, struct vnode **vpp); void vfs_add_vnodeops (const void *); @@ -548,11 +544,11 @@ void vfs_rm_vnodeops (const void *); int vflush (struct mount *mp, int rootrefs, int flags); int vmntvnodescan(struct mount *mp, int (*fastfunc)(struct mount *mp, struct vnode *vp, void *data), - int (*slowfunc)(struct mount *mp, struct vnode *vp, lwkt_tokref_t vlock, void *data), - void *data); + int (*slowfunc)(struct mount *mp, struct vnode *vp, lwkt_tokref_t vlock, + void *data), void *data); -int vget (struct vnode *vp, lwkt_tokref_t vlock, int lockflag, struct thread *td); -void vgone (struct vnode *vp); +int vget (struct vnode *vp, lwkt_tokref_t vlock, int lockflag, struct thread *td); +void vgone (struct vnode *vp); void vgonel (struct vnode *vp, lwkt_tokref_t vlock, struct thread *td); void vhold (struct vnode *); int vinvalbuf (struct vnode *vp, int save, @@ -562,7 +558,7 @@ int vtruncbuf (struct vnode *vp, struct thread *td, void vprint (char *label, struct vnode *vp); int vrecycle (struct vnode *vp, struct lwkt_tokref *inter_lkp, struct thread *td); -int vn_close (struct vnode *vp, int flags, struct thread *td); +int vn_close (struct vnode *vp, int flags, struct thread *td); int vn_isdisk (struct vnode *vp, int *errp); int vn_lock (struct vnode *vp, lwkt_tokref_t vlock, int flags, struct thread *td); #ifdef DEBUG_LOCKS @@ -570,7 +566,7 @@ int debug_vn_lock (struct vnode *vp, lwkt_tokref_t vlock, int flags, struct thre const char *filename, int line); #define vn_lock(vp,vlock,flags,p) debug_vn_lock(vp,vlock,flags,p,__FILE__,__LINE__) #endif -int vn_open (struct nameidata *ndp, int fmode, int cmode); +int vn_open (struct nameidata *ndp, int fmode, int cmode); void vn_pollevent (struct vnode *vp, int events); void vn_pollgone (struct vnode *vp); int vn_pollrecord (struct vnode *vp, struct thread *td, int events); @@ -584,7 +580,7 @@ int vn_stat (struct vnode *vp, struct stat *sb, struct thread *td); dev_t vn_todev (struct vnode *vp); int vfs_object_create (struct vnode *vp, struct thread *td); void vfs_timestamp (struct timespec *); -int vn_writechk (struct vnode *vp); +int vn_writechk (struct vnode *vp); int vop_stdbwrite (struct vop_bwrite_args *ap); int vop_stdislocked (struct vop_islocked_args *); int vop_stdlock (struct vop_lock_args *); @@ -608,8 +604,8 @@ int vop_stdcreatevobject (struct vop_createvobject_args *ap); int vop_stddestroyvobject (struct vop_destroyvobject_args *ap); int vop_stdgetvobject (struct vop_getvobject_args *ap); -void vput (struct vnode *vp); -void vrele (struct vnode *vp); +void vput (struct vnode *vp); +void vrele (struct vnode *vp); void vref (struct vnode *vp); extern vop_t **default_vnodeop_p; diff --git a/sys/vfs/fdesc/fdesc_vfsops.c b/sys/vfs/fdesc/fdesc_vfsops.c index fab2436c68..011feaed0e 100644 --- a/sys/vfs/fdesc/fdesc_vfsops.c +++ b/sys/vfs/fdesc/fdesc_vfsops.c @@ -36,7 +36,7 @@ * @(#)fdesc_vfsops.c 8.4 (Berkeley) 1/21/94 * * $FreeBSD: src/sys/miscfs/fdesc/fdesc_vfsops.c,v 1.22.2.3 2002/08/23 17:42:39 njl Exp $ - * $DragonFly: src/sys/vfs/fdesc/fdesc_vfsops.c,v 1.6 2004/03/01 06:33:20 dillon Exp $ + * $DragonFly: src/sys/vfs/fdesc/fdesc_vfsops.c,v 1.7 2004/04/24 04:32:03 drhodus Exp $ */ /* @@ -148,7 +148,7 @@ fdesc_root(struct mount *mp, struct vnode **vpp) * Return locked reference to root. */ vp = VFSTOFDESC(mp)->f_root; - VREF(vp); + vref(vp); vn_lock(vp, NULL, LK_EXCLUSIVE | LK_RETRY, td); *vpp = vp; return (0); diff --git a/sys/vfs/fdesc/fdesc_vnops.c b/sys/vfs/fdesc/fdesc_vnops.c index 2d38420dd3..5bc0834fb6 100644 --- a/sys/vfs/fdesc/fdesc_vnops.c +++ b/sys/vfs/fdesc/fdesc_vnops.c @@ -36,7 +36,7 @@ * @(#)fdesc_vnops.c 8.9 (Berkeley) 1/21/94 * * $FreeBSD: src/sys/miscfs/fdesc/fdesc_vnops.c,v 1.47.2.1 2001/10/22 22:49:26 chris Exp $ - * $DragonFly: src/sys/vfs/fdesc/fdesc_vnops.c,v 1.10 2004/04/01 19:08:15 cpressey Exp $ + * $DragonFly: src/sys/vfs/fdesc/fdesc_vnops.c,v 1.11 2004/04/24 04:32:03 drhodus Exp $ */ /* @@ -187,7 +187,7 @@ fdesc_lookup(struct vop_lookup_args *ap) VOP_UNLOCK(dvp, NULL, 0, td); if (cnp->cn_namelen == 1 && *pname == '.') { *vpp = dvp; - VREF(dvp); + vref(dvp); vn_lock(dvp, NULL, LK_SHARED | LK_RETRY, td); return (0); } diff --git a/sys/vfs/gnu/ext2fs/ext2_lookup.c b/sys/vfs/gnu/ext2fs/ext2_lookup.c index f45971baa9..fc1d6f28e1 100644 --- a/sys/vfs/gnu/ext2fs/ext2_lookup.c +++ b/sys/vfs/gnu/ext2fs/ext2_lookup.c @@ -5,7 +5,7 @@ * University of Utah, Department of Computer Science * * $FreeBSD: src/sys/gnu/ext2fs/ext2_lookup.c,v 1.21.2.3 2002/11/17 02:02:42 bde Exp $ - * $DragonFly: src/sys/vfs/gnu/ext2fs/ext2_lookup.c,v 1.12 2004/04/08 20:57:52 cpressey Exp $ + * $DragonFly: src/sys/vfs/gnu/ext2fs/ext2_lookup.c,v 1.13 2004/04/24 04:32:03 drhodus Exp $ */ /* * Copyright (c) 1989, 1993 @@ -592,7 +592,7 @@ found: else dp->i_count = dp->i_offset - prevoff; if (dp->i_number == dp->i_ino) { - VREF(vdp); + vref(vdp); *vpp = vdp; return (0); } @@ -675,7 +675,7 @@ found: } *vpp = tdp; } else if (dp->i_number == dp->i_ino) { - VREF(vdp); /* we want ourself, ie "." */ + vref(vdp); /* we want ourself, ie "." */ *vpp = vdp; } else { if ((error = VFS_VGET(vdp->v_mount, dp->i_ino, &tdp)) != 0) diff --git a/sys/vfs/gnu/ext2fs/ext2_vfsops.c b/sys/vfs/gnu/ext2fs/ext2_vfsops.c index 0fbf00d97e..da565f8768 100644 --- a/sys/vfs/gnu/ext2fs/ext2_vfsops.c +++ b/sys/vfs/gnu/ext2fs/ext2_vfsops.c @@ -38,7 +38,7 @@ * * @(#)ffs_vfsops.c 8.8 (Berkeley) 4/18/94 * $FreeBSD: src/sys/gnu/ext2fs/ext2_vfsops.c,v 1.63.2.7 2002/07/01 00:18:51 iedowse Exp $ - * $DragonFly: src/sys/vfs/gnu/ext2fs/ext2_vfsops.c,v 1.13 2004/04/08 20:57:52 cpressey Exp $ + * $DragonFly: src/sys/vfs/gnu/ext2fs/ext2_vfsops.c,v 1.14 2004/04/24 04:32:03 drhodus Exp $ */ #include "opt_quota.h" @@ -1126,7 +1126,7 @@ printf("ext2_vget(%d) dbn= %d ", ino, fsbtodb(fs, ino_to_fsba(fs, ino))); * Finish inode initialization now that aliasing has been resolved. */ ip->i_devvp = ump->um_devvp; - VREF(ip->i_devvp); + vref(ip->i_devvp); /* * Set up a generation number for this inode if it does not * already have one. This should only happen on old filesystems. diff --git a/sys/vfs/gnu/ext2fs/ext2_vnops.c b/sys/vfs/gnu/ext2fs/ext2_vnops.c index 78de68ad20..f686646e96 100644 --- a/sys/vfs/gnu/ext2fs/ext2_vnops.c +++ b/sys/vfs/gnu/ext2fs/ext2_vnops.c @@ -44,7 +44,7 @@ * @(#)ufs_vnops.c 8.27 (Berkeley) 5/27/95 * @(#)ext2_vnops.c 8.7 (Berkeley) 2/3/94 * $FreeBSD: src/sys/gnu/ext2fs/ext2_vnops.c,v 1.51.2.2 2003/01/02 17:26:18 bde Exp $ - * $DragonFly: src/sys/vfs/gnu/ext2fs/ext2_vnops.c,v 1.11 2004/04/08 20:57:52 cpressey Exp $ + * $DragonFly: src/sys/vfs/gnu/ext2fs/ext2_vnops.c,v 1.12 2004/04/24 04:32:03 drhodus Exp $ */ #include "opt_quota.h" @@ -507,7 +507,7 @@ abortit: error = ext2_checkpath(ip, dp, tcnp->cn_cred); if (error) goto out; - VREF(tdvp); + vref(tdvp); error = relookup(tdvp, &tvp, tcnp); if (error) goto out; @@ -634,7 +634,7 @@ abortit: */ fcnp->cn_flags &= ~CNP_MODMASK; fcnp->cn_flags |= CNP_LOCKPARENT | CNP_LOCKLEAF; - VREF(fdvp); + vref(fdvp); error = relookup(fdvp, &fvp, fcnp); if (error == 0) vrele(fdvp); diff --git a/sys/vfs/hpfs/hpfs_vfsops.c b/sys/vfs/hpfs/hpfs_vfsops.c index 21740fec63..60eed76d28 100644 --- a/sys/vfs/hpfs/hpfs_vfsops.c +++ b/sys/vfs/hpfs/hpfs_vfsops.c @@ -24,7 +24,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/fs/hpfs/hpfs_vfsops.c,v 1.3.2.2 2001/12/25 01:44:45 dillon Exp $ - * $DragonFly: src/sys/vfs/hpfs/hpfs_vfsops.c,v 1.14 2004/04/11 18:17:21 cpressey Exp $ + * $DragonFly: src/sys/vfs/hpfs/hpfs_vfsops.c,v 1.15 2004/04/24 04:32:04 drhodus Exp $ */ @@ -635,7 +635,7 @@ hpfs_vget(struct mount *mp, ino_t ino, struct vnode **vpp) hp->h_gid = hpmp->hpm_uid; hp->h_mode = hpmp->hpm_mode; hp->h_devvp = hpmp->hpm_devvp; - VREF(hp->h_devvp); + vref(hp->h_devvp); error = VN_LOCK(vp, LK_EXCLUSIVE, td); if (error) { diff --git a/sys/vfs/hpfs/hpfs_vnops.c b/sys/vfs/hpfs/hpfs_vnops.c index 195abe9dbd..b673aa768c 100644 --- a/sys/vfs/hpfs/hpfs_vnops.c +++ b/sys/vfs/hpfs/hpfs_vnops.c @@ -24,7 +24,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/fs/hpfs/hpfs_vnops.c,v 1.2.2.2 2002/01/15 18:35:09 semenu Exp $ - * $DragonFly: src/sys/vfs/hpfs/hpfs_vnops.c,v 1.13 2004/04/11 18:17:21 cpressey Exp $ + * $DragonFly: src/sys/vfs/hpfs/hpfs_vnops.c,v 1.14 2004/04/24 04:32:04 drhodus Exp $ */ #include @@ -1138,7 +1138,7 @@ hpfs_lookup(struct vop_lookup_args *ap) !strncmp(cnp->cn_nameptr,".",1) ) { dprintf(("hpfs_lookup(0x%x,...): . faked\n",dhp->h_no)); - VREF(dvp); + vref(dvp); *ap->a_vpp = dvp; return (0); @@ -1194,7 +1194,7 @@ hpfs_lookup(struct vop_lookup_args *ap) if (dhp->h_no == dep->de_fnode) { brelse(bp); - VREF(dvp); + vref(dvp); *ap->a_vpp = dvp; return (0); } diff --git a/sys/vfs/isofs/cd9660/cd9660_lookup.c b/sys/vfs/isofs/cd9660/cd9660_lookup.c index 21f81a85eb..81d1ea3bb6 100644 --- a/sys/vfs/isofs/cd9660/cd9660_lookup.c +++ b/sys/vfs/isofs/cd9660/cd9660_lookup.c @@ -39,7 +39,7 @@ * * @(#)cd9660_lookup.c 8.2 (Berkeley) 1/23/94 * $FreeBSD: src/sys/isofs/cd9660/cd9660_lookup.c,v 1.23.2.2 2001/11/04 06:19:47 dillon Exp $ - * $DragonFly: src/sys/vfs/isofs/cd9660/cd9660_lookup.c,v 1.11 2004/04/12 23:18:55 cpressey Exp $ + * $DragonFly: src/sys/vfs/isofs/cd9660/cd9660_lookup.c,v 1.12 2004/04/24 04:32:04 drhodus Exp $ */ #include @@ -370,7 +370,7 @@ found: *vpp = tdp; } else if (dp->i_number == dp->i_ino) { brelse(bp); - VREF(vdp); /* we want ourself, ie "." */ + vref(vdp); /* we want ourself, ie "." */ *vpp = vdp; } else { error = cd9660_vget_internal(vdp->v_mount, dp->i_ino, &tdp, diff --git a/sys/vfs/isofs/cd9660/cd9660_vfsops.c b/sys/vfs/isofs/cd9660/cd9660_vfsops.c index 5c0d52a15d..8fafed0375 100644 --- a/sys/vfs/isofs/cd9660/cd9660_vfsops.c +++ b/sys/vfs/isofs/cd9660/cd9660_vfsops.c @@ -37,7 +37,7 @@ * * @(#)cd9660_vfsops.c 8.18 (Berkeley) 5/22/95 * $FreeBSD: src/sys/isofs/cd9660/cd9660_vfsops.c,v 1.74.2.7 2002/04/08 09:39:29 bde Exp $ - * $DragonFly: src/sys/vfs/isofs/cd9660/cd9660_vfsops.c,v 1.13 2004/04/12 23:18:55 cpressey Exp $ + * $DragonFly: src/sys/vfs/isofs/cd9660/cd9660_vfsops.c,v 1.14 2004/04/24 04:32:04 drhodus Exp $ */ #include @@ -776,7 +776,7 @@ cd9660_vget_internal(struct mount *mp, ino_t ino, struct vnode **vpp, ip->i_mnt = imp; ip->i_devvp = imp->im_devvp; - VREF(ip->i_devvp); + vref(ip->i_devvp); if (relocated) { /* diff --git a/sys/vfs/msdosfs/msdosfs_denode.c b/sys/vfs/msdosfs/msdosfs_denode.c index 34a9d6152b..7c0ca6915f 100644 --- a/sys/vfs/msdosfs/msdosfs_denode.c +++ b/sys/vfs/msdosfs/msdosfs_denode.c @@ -1,5 +1,5 @@ /* $FreeBSD: src/sys/msdosfs/msdosfs_denode.c,v 1.47.2.3 2002/08/22 16:20:15 trhodes Exp $ */ -/* $DragonFly: src/sys/vfs/msdosfs/msdosfs_denode.c,v 1.11 2004/04/17 00:30:17 cpressey Exp $ */ +/* $DragonFly: src/sys/vfs/msdosfs/msdosfs_denode.c,v 1.12 2004/04/24 04:32:04 drhodus Exp $ */ /* $NetBSD: msdosfs_denode.c,v 1.28 1998/02/10 14:10:00 mrg Exp $ */ /*- @@ -265,7 +265,7 @@ deget(struct msdosfsmount *pmp, /* so we know the maj/min number */ * Directory entry was not in cache, have to create a vnode and * copy it from the passed disk buffer. */ - /* getnewvnode() does a VREF() on the vnode */ + /* getnewvnode() does a vref() on the vnode */ error = getnewvnode(VT_MSDOSFS, mntp, msdosfs_vnodeop_p, &nvp); if (error) { *depp = NULL; @@ -394,7 +394,7 @@ deget(struct msdosfsmount *pmp, /* so we know the maj/min number */ SETHIGH(ldep->de_modrev, tv.tv_sec); SETLOW(ldep->de_modrev, tv.tv_usec * 4294); ldep->de_devvp = pmp->pm_devvp; - VREF(ldep->de_devvp); + vref(ldep->de_devvp); *depp = ldep; return (0); } diff --git a/sys/vfs/msdosfs/msdosfs_lookup.c b/sys/vfs/msdosfs/msdosfs_lookup.c index 4645744006..beb22488de 100644 --- a/sys/vfs/msdosfs/msdosfs_lookup.c +++ b/sys/vfs/msdosfs/msdosfs_lookup.c @@ -1,5 +1,5 @@ /* $FreeBSD: src/sys/msdosfs/msdosfs_lookup.c,v 1.30.2.1 2000/11/03 15:55:39 bp Exp $ */ -/* $DragonFly: src/sys/vfs/msdosfs/msdosfs_lookup.c,v 1.9 2004/04/17 00:30:17 cpressey Exp $ */ +/* $DragonFly: src/sys/vfs/msdosfs/msdosfs_lookup.c,v 1.10 2004/04/24 04:32:04 drhodus Exp $ */ /* $NetBSD: msdosfs_lookup.c,v 1.37 1997/11/17 15:36:54 ws Exp $ */ /*- @@ -446,7 +446,7 @@ foundroot: * Save directory inode pointer in ndp->ni_dvp for dirremove(). */ if (dp->de_StartCluster == scn && isadir) { /* "." */ - VREF(vdp); + vref(vdp); *vpp = vdp; return (0); } @@ -533,7 +533,7 @@ foundroot: } *vpp = DETOV(tdp); } else if (dp->de_StartCluster == scn && isadir) { - VREF(vdp); /* we want ourself, ie "." */ + vref(vdp); /* we want ourself, ie "." */ *vpp = vdp; } else { if ((error = deget(pmp, cluster, blkoff, &tdp)) != 0) diff --git a/sys/vfs/nfs/nfs_serv.c b/sys/vfs/nfs/nfs_serv.c index 9d8e93b32f..e6cb06c026 100644 --- a/sys/vfs/nfs/nfs_serv.c +++ b/sys/vfs/nfs/nfs_serv.c @@ -35,7 +35,7 @@ * * @(#)nfs_serv.c 8.8 (Berkeley) 7/31/95 * $FreeBSD: src/sys/nfs/nfs_serv.c,v 1.93.2.6 2002/12/29 18:19:53 dillon Exp $ - * $DragonFly: src/sys/vfs/nfs/nfs_serv.c,v 1.14 2004/04/19 16:33:49 cpressey Exp $ + * $DragonFly: src/sys/vfs/nfs/nfs_serv.c,v 1.15 2004/04/24 04:32:04 drhodus Exp $ */ /* @@ -525,7 +525,7 @@ nfsrv_lookup(struct nfsrv_descript *nfsd, struct nfssvc_sock *slp, ind.ni_cnd.cn_nameptr = ind.ni_cnd.cn_pnbuf = nfs_pub.np_index; ind.ni_startdir = nd.ni_vp; - VREF(ind.ni_startdir); + vref(ind.ni_startdir); error = lookup(&ind); ind.ni_dvp = NULL; diff --git a/sys/vfs/nfs/nfs_subs.c b/sys/vfs/nfs/nfs_subs.c index b542be1479..f40f172f91 100644 --- a/sys/vfs/nfs/nfs_subs.c +++ b/sys/vfs/nfs/nfs_subs.c @@ -35,7 +35,7 @@ * * @(#)nfs_subs.c 8.8 (Berkeley) 5/22/95 * $FreeBSD: /repoman/r/ncvs/src/sys/nfsclient/nfs_subs.c,v 1.128 2004/04/14 23:23:55 peadar Exp $ - * $DragonFly: src/sys/vfs/nfs/nfs_subs.c,v 1.15 2004/04/23 18:01:07 dillon Exp $ + * $DragonFly: src/sys/vfs/nfs/nfs_subs.c,v 1.16 2004/04/24 04:32:04 drhodus Exp $ */ /* @@ -1573,7 +1573,7 @@ nfs_namei(struct nameidata *ndp, fhandle_t *fhp, int len, */ cnp->cn_td = td; - VREF(dp); + vref(dp); ndp->ni_startdir = dp; for (;;) { @@ -1675,7 +1675,7 @@ nfs_namei(struct nameidata *ndp, fhandle_t *fhp, int len, if (cnp->cn_pnbuf[0] == '/') { vrele(ndp->ni_dvp); ndp->ni_dvp = ndp->ni_rootdir; - VREF(ndp->ni_dvp); + vref(ndp->ni_dvp); } ndp->ni_startdir = ndp->ni_dvp; ndp->ni_dvp = NULL; diff --git a/sys/vfs/nfs/nfs_vfsops.c b/sys/vfs/nfs/nfs_vfsops.c index 55a1ce7ed0..df97391f0f 100644 --- a/sys/vfs/nfs/nfs_vfsops.c +++ b/sys/vfs/nfs/nfs_vfsops.c @@ -35,7 +35,7 @@ * * @(#)nfs_vfsops.c 8.12 (Berkeley) 5/20/95 * $FreeBSD: src/sys/nfs/nfs_vfsops.c,v 1.91.2.7 2003/01/27 20:04:08 dillon Exp $ - * $DragonFly: src/sys/vfs/nfs/nfs_vfsops.c,v 1.15 2004/04/07 05:15:48 dillon Exp $ + * $DragonFly: src/sys/vfs/nfs/nfs_vfsops.c,v 1.16 2004/04/24 04:32:04 drhodus Exp $ */ #include "opt_bootp.h" @@ -551,7 +551,7 @@ nfs_mountroot(mp) */ vp->v_type = VREG; vp->v_flag = 0; - VREF(vp); + vref(vp); swaponvp(td, vp, NODEV, nd->swap_nblks); } diff --git a/sys/vfs/nfs/nfs_vnops.c b/sys/vfs/nfs/nfs_vnops.c index 71ed66ac99..1b5c470bcf 100644 --- a/sys/vfs/nfs/nfs_vnops.c +++ b/sys/vfs/nfs/nfs_vnops.c @@ -35,7 +35,7 @@ * * @(#)nfs_vnops.c 8.16 (Berkeley) 5/27/95 * $FreeBSD: src/sys/nfs/nfs_vnops.c,v 1.150.2.5 2001/12/20 19:56:28 dillon Exp $ - * $DragonFly: src/sys/vfs/nfs/nfs_vnops.c,v 1.21 2004/04/19 16:33:49 cpressey Exp $ + * $DragonFly: src/sys/vfs/nfs/nfs_vnops.c,v 1.22 2004/04/24 04:32:04 drhodus Exp $ */ @@ -884,7 +884,7 @@ nfs_lookup(struct vop_lookup_args *ap) * for an explanation of the locking protocol */ if (dvp == newvp) { - VREF(newvp); + vref(newvp); error = 0; } else if (flags & CNP_ISDOTDOT) { VOP_UNLOCK(dvp, NULL, 0, td); @@ -997,7 +997,7 @@ nfs_lookup(struct vop_lookup_args *ap) return (error); } } else if (NFS_CMPFH(np, fhp, fhsize)) { - VREF(dvp); + vref(dvp); newvp = dvp; } else { error = nfs_nget(dvp->v_mount, fhp, fhsize, &np); @@ -2411,7 +2411,7 @@ nfs_readdirplusrpc(struct vnode *vp, struct uio *uiop) if (doit) { nfsm_getfh(fhp, fhsize, 1); if (NFS_CMPFH(dnp, fhp, fhsize)) { - VREF(vp); + vref(vp); newvp = vp; np = dnp; } else { @@ -2522,7 +2522,7 @@ nfs_sillyrename(struct vnode *dvp, struct vnode *vp, struct componentname *cnp) M_NFSREQ, M_WAITOK); sp->s_cred = crdup(cnp->cn_cred); sp->s_dvp = dvp; - VREF(dvp); + vref(dvp); /* Fudge together a funny name */ sp->s_namlen = sprintf(sp->s_name, ".nfsA%08x4.4", (int)cnp->cn_td); @@ -2592,7 +2592,7 @@ nfs_lookitup(struct vnode *dvp, const char *name, int len, struct ucred *cred, np->n_fhsize = fhlen; newvp = NFSTOV(np); } else if (NFS_CMPFH(dnp, nfhp, fhlen)) { - VREF(dvp); + vref(dvp); newvp = dvp; } else { error = nfs_nget(dvp->v_mount, nfhp, fhlen, &np); diff --git a/sys/vfs/ntfs/ntfs_subr.c b/sys/vfs/ntfs/ntfs_subr.c index 06a628f4ac..b612576704 100644 --- a/sys/vfs/ntfs/ntfs_subr.c +++ b/sys/vfs/ntfs/ntfs_subr.c @@ -26,7 +26,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/ntfs/ntfs_subr.c,v 1.7.2.4 2001/10/12 22:08:49 semenu Exp $ - * $DragonFly: src/sys/vfs/ntfs/ntfs_subr.c,v 1.12 2004/04/20 19:59:30 cpressey Exp $ + * $DragonFly: src/sys/vfs/ntfs/ntfs_subr.c,v 1.13 2004/04/24 04:32:04 drhodus Exp $ */ #include @@ -390,7 +390,7 @@ ntfs_ntlookup(struct ntfsmount *ntmp, ino_t ino, struct ntnode **ipp) ip->i_mp = ntmp; LIST_INIT(&ip->i_fnlist); - VREF(ip->i_devvp); + vref(ip->i_devvp); /* init lock and lock the newborn ntnode */ lockinit(&ip->i_lock, 0, "ntnode", 0, LK_EXCLUSIVE); @@ -905,7 +905,7 @@ ntfs_ntlookupfile(struct ntfsmount *ntmp, struct vnode *vp, (attrname && fp->f_attrname && !strcmp(attrname, fp->f_attrname)))) { - VREF(vp); + vref(vp); *vpp = vp; error = 0; goto fail; diff --git a/sys/vfs/ntfs/ntfs_vfsops.c b/sys/vfs/ntfs/ntfs_vfsops.c index dd457d95e7..918696ea02 100644 --- a/sys/vfs/ntfs/ntfs_vfsops.c +++ b/sys/vfs/ntfs/ntfs_vfsops.c @@ -26,7 +26,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/ntfs/ntfs_vfsops.c,v 1.20.2.5 2001/12/25 01:44:45 dillon Exp $ - * $DragonFly: src/sys/vfs/ntfs/ntfs_vfsops.c,v 1.14 2004/04/20 19:59:30 cpressey Exp $ + * $DragonFly: src/sys/vfs/ntfs/ntfs_vfsops.c,v 1.15 2004/04/24 04:32:04 drhodus Exp $ */ @@ -517,7 +517,7 @@ ntfs_mountfs(struct vnode *devvp, struct mount *mp, struct ntfs_args *argsp, if(error) goto out1; ntmp->ntm_sysvn[pi[i]]->v_flag |= VSYSTEM; - VREF(ntmp->ntm_sysvn[pi[i]]); + vref(ntmp->ntm_sysvn[pi[i]]); vput(ntmp->ntm_sysvn[pi[i]]); } } diff --git a/sys/vfs/ntfs/ntfs_vnops.c b/sys/vfs/ntfs/ntfs_vnops.c index c2373b1db6..bb27efa9ef 100644 --- a/sys/vfs/ntfs/ntfs_vnops.c +++ b/sys/vfs/ntfs/ntfs_vnops.c @@ -36,7 +36,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/ntfs/ntfs_vnops.c,v 1.9.2.4 2002/08/06 19:35:18 semenu Exp $ - * $DragonFly: src/sys/vfs/ntfs/ntfs_vnops.c,v 1.11 2004/04/20 19:59:30 cpressey Exp $ + * $DragonFly: src/sys/vfs/ntfs/ntfs_vnops.c,v 1.12 2004/04/24 04:32:04 drhodus Exp $ * */ @@ -747,7 +747,7 @@ ntfs_lookup(struct vop_lookup_args *ap) dprintf(("ntfs_lookup: faking . directory in %d\n", dip->i_number)); - VREF(dvp); + vref(dvp); *ap->a_vpp = dvp; error = 0; } else if (cnp->cn_flags & CNP_ISDOTDOT) { diff --git a/sys/vfs/nullfs/null.h b/sys/vfs/nullfs/null.h index 33fe5b6b65..5b67cd330c 100644 --- a/sys/vfs/nullfs/null.h +++ b/sys/vfs/nullfs/null.h @@ -36,7 +36,7 @@ * @(#)null.h 8.3 (Berkeley) 8/20/94 * * $FreeBSD: src/sys/miscfs/nullfs/null.h,v 1.11.2.3 2001/06/26 04:20:09 bp Exp $ - * $DragonFly: src/sys/vfs/nullfs/null.h,v 1.2 2003/06/17 04:28:42 dillon Exp $ + * $DragonFly: src/sys/vfs/nullfs/null.h,v 1.3 2004/04/24 04:32:04 drhodus Exp $ */ struct null_args { @@ -56,7 +56,7 @@ struct null_node { struct lock null_lock; /* Lock for this vnode. MBF */ struct lock *null_vnlock; /* lock of lower vnode in the stack */ LIST_ENTRY(null_node) null_hash; /* Hash list */ - struct vnode *null_lowervp; /* VREFed once */ + struct vnode *null_lowervp; /* vrefed once */ struct vnode *null_vnode; /* Back pointer */ }; diff --git a/sys/vfs/nullfs/null_subr.c b/sys/vfs/nullfs/null_subr.c index c2b46ae976..92e0ab56e3 100644 --- a/sys/vfs/nullfs/null_subr.c +++ b/sys/vfs/nullfs/null_subr.c @@ -36,7 +36,7 @@ * @(#)null_subr.c 8.7 (Berkeley) 5/14/95 * * $FreeBSD: src/sys/miscfs/nullfs/null_subr.c,v 1.21.2.4 2001/06/26 04:20:09 bp Exp $ - * $DragonFly: src/sys/vfs/nullfs/Attic/null_subr.c,v 1.8 2004/04/21 16:55:09 cpressey Exp $ + * $DragonFly: src/sys/vfs/nullfs/Attic/null_subr.c,v 1.9 2004/04/24 04:32:04 drhodus Exp $ */ #include @@ -55,7 +55,7 @@ * Null layer cache: * Each cache entry holds a reference to the lower vnode * along with a pointer to the alias vnode. When an - * entry is added the lower vnode is VREF'd. When the + * entry is added the lower vnode is vref'd. When the * alias is removed the lower vnode is vrele'd. */ @@ -96,7 +96,7 @@ nullfs_uninit(struct vfsconf *vfsp) } /* - * Return a VREF'ed alias for lower vnode if already exists, else 0. + * Return a vref'ed alias for lower vnode if already exists, else 0. * Lower vnode should be locked on entry and will be left locked on exit. */ static struct vnode * @@ -111,7 +111,7 @@ null_node_find(struct mount *mp, struct vnode *lowervp) * Find hash base, and then search the (two-way) linked * list looking for a null_node structure which is referencing * the lower vnode. If found, the increment the null_node - * reference count (but NOT the lower vnode's VREF counter). + * reference count (but NOT the lower vnode's vref counter). */ hd = NULL_NHASH(lowervp); loop: @@ -214,7 +214,7 @@ null_node_alloc(struct mount *mp, struct vnode *lowervp, struct vnode **vpp) if (error) panic("null_node_alloc: can't lock new vnode\n"); - VREF(lowervp); + vref(lowervp); hd = NULL_NHASH(lowervp); LIST_INSERT_HEAD(hd, xp, null_hash); lockmgr(&null_hashlock, LK_RELEASE, NULL, td); @@ -258,7 +258,7 @@ null_node_create(struct mount *mp, struct vnode *lowervp, struct vnode **newvpp) return error; /* - * aliasvp is already VREF'd by getnewvnode() + * aliasvp is already vref'd by getnewvnode() */ } diff --git a/sys/vfs/nullfs/null_vfsops.c b/sys/vfs/nullfs/null_vfsops.c index 4d7de4e59e..66f2de6582 100644 --- a/sys/vfs/nullfs/null_vfsops.c +++ b/sys/vfs/nullfs/null_vfsops.c @@ -37,7 +37,7 @@ * * @(#)lofs_vfsops.c 1.2 (Berkeley) 6/18/92 * $FreeBSD: src/sys/miscfs/nullfs/null_vfsops.c,v 1.35.2.3 2001/07/26 20:37:11 iedowse Exp $ - * $DragonFly: src/sys/vfs/nullfs/null_vfsops.c,v 1.8 2004/04/21 16:55:09 cpressey Exp $ + * $DragonFly: src/sys/vfs/nullfs/null_vfsops.c,v 1.9 2004/04/24 04:32:04 drhodus Exp $ */ /* @@ -254,7 +254,7 @@ nullfs_root(struct mount *mp, struct vnode **vpp) * Return locked reference to root. */ vp = MOUNTTONULLMOUNT(mp)->nullm_rootvp; - VREF(vp); + vref(vp); #ifdef NULLFS_DEBUG if (VOP_ISLOCKED(vp, NULL)) { diff --git a/sys/vfs/nullfs/null_vnops.c b/sys/vfs/nullfs/null_vnops.c index 21e1d1747f..299066d871 100644 --- a/sys/vfs/nullfs/null_vnops.c +++ b/sys/vfs/nullfs/null_vnops.c @@ -38,7 +38,7 @@ * Ancestors: * @(#)lofs_vnops.c 1.2 (Berkeley) 6/18/92 * $FreeBSD: src/sys/miscfs/nullfs/null_vnops.c,v 1.38.2.6 2002/07/31 00:32:28 semenu Exp $ - * $DragonFly: src/sys/vfs/nullfs/null_vnops.c,v 1.10 2004/04/21 16:55:09 cpressey Exp $ + * $DragonFly: src/sys/vfs/nullfs/null_vnops.c,v 1.11 2004/04/24 04:32:04 drhodus Exp $ * ...and... * @(#)null_vnodeops.c 1.20 92/07/07 UCLA Ficus project * @@ -284,7 +284,7 @@ null_bypass(struct vop_generic_args *ap) * that. (This should go away in the future.) */ if (reles & VDESC_VP0_WILLRELE) - VREF(*this_vp_p); + vref(*this_vp_p); } } @@ -323,7 +323,7 @@ null_bypass(struct vop_generic_args *ap) /* * Map the possible out-going vpp * (Assumes that the lower layer always returns - * a VREF'ed vpp unless it gets an error.) + * a vref'ed vpp unless it gets an error.) */ if (descp->vdesc_vpp_offset != VDESC_NO_OFFSET && !(descp->vdesc_flags & VDESC_NOMAP_VPP) && @@ -388,7 +388,7 @@ null_lookup(struct vop_lookup_args *ap) if ((error == 0 || error == EJUSTRETURN) && lvp != NULL) { if (ldvp == lvp) { *ap->a_vpp = dvp; - VREF(dvp); + vref(dvp); vrele(lvp); } else { error = null_node_create(dvp->v_mount, lvp, &vp); diff --git a/sys/vfs/nwfs/nwfs_vnops.c b/sys/vfs/nwfs/nwfs_vnops.c index 1f43668d98..23014030ee 100644 --- a/sys/vfs/nwfs/nwfs_vnops.c +++ b/sys/vfs/nwfs/nwfs_vnops.c @@ -30,7 +30,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/nwfs/nwfs_vnops.c,v 1.6.2.3 2001/03/14 11:26:59 bp Exp $ - * $DragonFly: src/sys/vfs/nwfs/nwfs_vnops.c,v 1.11 2004/04/22 17:56:44 cpressey Exp $ + * $DragonFly: src/sys/vfs/nwfs/nwfs_vnops.c,v 1.12 2004/04/24 04:32:05 drhodus Exp $ */ #include #include @@ -985,7 +985,7 @@ printf("dvp %d:%d:%d\n", (int)mp, (int)dvp->v_flag & VROOT, (int)flags & CNP_ISD error = VOP_ACCESS(dvp, VWRITE, cnp->cn_cred, cnp->cn_td); if (error) return (error); if (NWCMPF(&dnp->n_fid, &fid)) { /* we found ourselfs */ - VREF(dvp); + vref(dvp); *vpp = dvp; return 0; } diff --git a/sys/vfs/portal/portal_vfsops.c b/sys/vfs/portal/portal_vfsops.c index 152cb53e28..49e9632825 100644 --- a/sys/vfs/portal/portal_vfsops.c +++ b/sys/vfs/portal/portal_vfsops.c @@ -36,7 +36,7 @@ * @(#)portal_vfsops.c 8.11 (Berkeley) 5/14/95 * * $FreeBSD: src/sys/miscfs/portal/portal_vfsops.c,v 1.26.2.2 2001/07/26 20:37:16 iedowse Exp $ - * $DragonFly: src/sys/vfs/portal/portal_vfsops.c,v 1.7 2004/04/23 17:35:58 cpressey Exp $ + * $DragonFly: src/sys/vfs/portal/portal_vfsops.c,v 1.8 2004/04/24 04:32:05 drhodus Exp $ */ /* @@ -200,7 +200,7 @@ portal_root(struct mount *mp, struct vnode **vpp) * Return locked reference to root. */ vp = VFSTOPORTAL(mp)->pm_root; - VREF(vp); + vref(vp); vn_lock(vp, NULL, LK_EXCLUSIVE | LK_RETRY, td); *vpp = vp; return (0); diff --git a/sys/vfs/portal/portal_vnops.c b/sys/vfs/portal/portal_vnops.c index 81d4e22af8..d0bb3440ba 100644 --- a/sys/vfs/portal/portal_vnops.c +++ b/sys/vfs/portal/portal_vnops.c @@ -36,7 +36,7 @@ * @(#)portal_vnops.c 8.14 (Berkeley) 5/21/95 * * $FreeBSD: src/sys/miscfs/portal/portal_vnops.c,v 1.38 1999/12/21 06:29:00 chris Exp $ - * $DragonFly: src/sys/vfs/portal/portal_vnops.c,v 1.11 2004/04/23 17:35:58 cpressey Exp $ + * $DragonFly: src/sys/vfs/portal/portal_vnops.c,v 1.12 2004/04/24 04:32:05 drhodus Exp $ */ /* @@ -122,7 +122,7 @@ portal_lookup(struct vop_lookup_args *ap) if (cnp->cn_namelen == 1 && *pname == '.') { *vpp = dvp; - VREF(dvp); + vref(dvp); /*VOP_LOCK(dvp);*/ return (0); } diff --git a/sys/vfs/procfs/procfs_vnops.c b/sys/vfs/procfs/procfs_vnops.c index 8ce7325640..f46bdbb983 100644 --- a/sys/vfs/procfs/procfs_vnops.c +++ b/sys/vfs/procfs/procfs_vnops.c @@ -37,7 +37,7 @@ * @(#)procfs_vnops.c 8.18 (Berkeley) 5/21/95 * * $FreeBSD: src/sys/miscfs/procfs/procfs_vnops.c,v 1.76.2.7 2002/01/22 17:22:59 nectar Exp $ - * $DragonFly: src/sys/vfs/procfs/procfs_vnops.c,v 1.11 2004/03/01 06:33:22 dillon Exp $ + * $DragonFly: src/sys/vfs/procfs/procfs_vnops.c,v 1.12 2004/04/24 04:32:05 drhodus Exp $ */ /* @@ -716,7 +716,7 @@ procfs_lookup(ap) if (cnp->cn_namelen == 1 && *pname == '.') { *vpp = dvp; - VREF(dvp); + vref(dvp); /* vn_lock(dvp, NULL, LK_EXCLUSIVE | LK_RETRY, curp); */ return (0); } diff --git a/sys/vfs/smbfs/smbfs_vnops.c b/sys/vfs/smbfs/smbfs_vnops.c index 20628f6ee6..e64b8e6020 100644 --- a/sys/vfs/smbfs/smbfs_vnops.c +++ b/sys/vfs/smbfs/smbfs_vnops.c @@ -30,7 +30,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/fs/smbfs/smbfs_vnops.c,v 1.2.2.8 2003/04/04 08:57:23 tjr Exp $ - * $DragonFly: src/sys/vfs/smbfs/smbfs_vnops.c,v 1.11 2004/03/01 06:33:23 dillon Exp $ + * $DragonFly: src/sys/vfs/smbfs/smbfs_vnops.c,v 1.12 2004/04/24 04:32:05 drhodus Exp $ */ #include #include @@ -1270,7 +1270,7 @@ smbfs_lookup(ap) if (error) return error; if (isdot) { - VREF(dvp); + vref(dvp); *vpp = dvp; return 0; } diff --git a/sys/vfs/udf/udf_vfsops.c b/sys/vfs/udf/udf_vfsops.c index 00135f89fc..6f5c3707e5 100644 --- a/sys/vfs/udf/udf_vfsops.c +++ b/sys/vfs/udf/udf_vfsops.c @@ -24,7 +24,7 @@ * SUCH DAMAGE. * * $FreeBSD: src/sys/fs/udf/udf_vfsops.c,v 1.16 2003/11/05 06:56:08 scottl Exp $ - * $DragonFly: src/sys/vfs/udf/udf_vfsops.c,v 1.3 2004/03/29 16:38:36 dillon Exp $ + * $DragonFly: src/sys/vfs/udf/udf_vfsops.c,v 1.4 2004/04/24 04:32:05 drhodus Exp $ */ /* udf_vfsops.c */ @@ -538,7 +538,7 @@ udf_vget(struct mount *mp, ino_t ino, struct vnode **vpp) unode->i_dev = udfmp->im_dev; unode->udfmp = udfmp; vp->v_data = unode; - VREF(udfmp->im_devvp); + vref(udfmp->im_devvp); udf_hashins(unode); switch (unode->fentry->icbtag.file_type) { diff --git a/sys/vfs/ufs/ffs_vfsops.c b/sys/vfs/ufs/ffs_vfsops.c index 9e92581d68..86ad6ed052 100644 --- a/sys/vfs/ufs/ffs_vfsops.c +++ b/sys/vfs/ufs/ffs_vfsops.c @@ -32,7 +32,7 @@ * * @(#)ffs_vfsops.c 8.31 (Berkeley) 5/20/95 * $FreeBSD: src/sys/ufs/ffs/ffs_vfsops.c,v 1.117.2.10 2002/06/23 22:34:52 iedowse Exp $ - * $DragonFly: src/sys/vfs/ufs/ffs_vfsops.c,v 1.15 2004/03/11 20:17:36 hmp Exp $ + * $DragonFly: src/sys/vfs/ufs/ffs_vfsops.c,v 1.16 2004/04/24 04:32:05 drhodus Exp $ */ #include "opt_quota.h" @@ -1092,7 +1092,7 @@ ffs_sync_scan2(struct mount *mp, struct vnode *vp, * getting ripped out from under UFS_UPDATE, since * we are not holding a vnode lock. */ - VREF(vp); + vref(vp); lwkt_reltoken(vlock); /* UFS_UPDATE(vp, waitfor == MNT_WAIT); */ UFS_UPDATE(vp, 0); @@ -1230,7 +1230,7 @@ restart: * Finish inode initialization now that aliasing has been resolved. */ ip->i_devvp = ump->um_devvp; - VREF(ip->i_devvp); + vref(ip->i_devvp); /* * Set up a generation number for this inode if it does not * already have one. This should only happen on old filesystems. diff --git a/sys/vfs/ufs/ufs_lookup.c b/sys/vfs/ufs/ufs_lookup.c index beb6f478ef..4508e3e016 100644 --- a/sys/vfs/ufs/ufs_lookup.c +++ b/sys/vfs/ufs/ufs_lookup.c @@ -37,7 +37,7 @@ * * @(#)ufs_lookup.c 8.15 (Berkeley) 6/16/95 * $FreeBSD: src/sys/ufs/ufs/ufs_lookup.c,v 1.33.2.7 2001/09/22 19:22:13 iedowse Exp $ - * $DragonFly: src/sys/vfs/ufs/ufs_lookup.c,v 1.10 2004/04/02 05:46:03 hmp Exp $ + * $DragonFly: src/sys/vfs/ufs/ufs_lookup.c,v 1.11 2004/04/24 04:32:05 drhodus Exp $ */ #include "opt_ufs.h" @@ -503,7 +503,7 @@ found: else dp->i_count = dp->i_offset - prevoff; if (dp->i_number == dp->i_ino) { - VREF(vdp); + vref(vdp); *vpp = vdp; return (0); } @@ -607,7 +607,7 @@ found: } *vpp = tdp; } else if (dp->i_number == dp->i_ino) { - VREF(vdp); /* we want ourself, ie "." */ + vref(vdp); /* we want ourself, ie "." */ *vpp = vdp; } else { error = VFS_VGET(vdp->v_mount, dp->i_ino, &tdp); diff --git a/sys/vfs/ufs/ufs_vnops.c b/sys/vfs/ufs/ufs_vnops.c index 9d4df89089..89fd02a73e 100644 --- a/sys/vfs/ufs/ufs_vnops.c +++ b/sys/vfs/ufs/ufs_vnops.c @@ -37,7 +37,7 @@ * * @(#)ufs_vnops.c 8.27 (Berkeley) 5/27/95 * $FreeBSD: src/sys/ufs/ufs/ufs_vnops.c,v 1.131.2.8 2003/01/02 17:26:19 bde Exp $ - * $DragonFly: src/sys/vfs/ufs/ufs_vnops.c,v 1.11 2004/03/01 06:33:23 dillon Exp $ + * $DragonFly: src/sys/vfs/ufs/ufs_vnops.c,v 1.12 2004/04/24 04:32:05 drhodus Exp $ */ #include "opt_quota.h" @@ -1011,7 +1011,7 @@ abortit: goto out; if ((tcnp->cn_flags & CNP_SAVESTART) == 0) panic("ufs_rename: lost to startdir"); - VREF(tdvp); + vref(tdvp); error = relookup(tdvp, &tvp, tcnp); if (error) goto out; @@ -1158,7 +1158,7 @@ abortit: fcnp->cn_flags |= CNP_LOCKPARENT | CNP_LOCKLEAF; if ((fcnp->cn_flags & CNP_SAVESTART) == 0) panic("ufs_rename: lost from startdir"); - VREF(fdvp); + vref(fdvp); error = relookup(fdvp, &fvp, fcnp); if (error == 0) vrele(fdvp); diff --git a/sys/vfs/umapfs/umap.h b/sys/vfs/umapfs/umap.h index 0c9fb9c8ae..5d37241f00 100644 --- a/sys/vfs/umapfs/umap.h +++ b/sys/vfs/umapfs/umap.h @@ -36,7 +36,7 @@ * @(#)umap.h 8.4 (Berkeley) 8/20/94 * * $FreeBSD: src/sys/miscfs/umapfs/umap.h,v 1.13 1999/12/29 04:54:47 peter Exp $ - * $DragonFly: src/sys/vfs/umapfs/Attic/umap.h,v 1.3 2003/08/20 09:56:34 rob Exp $ + * $DragonFly: src/sys/vfs/umapfs/Attic/umap.h,v 1.4 2004/04/24 04:32:05 drhodus Exp $ */ #define MAPFILEENTRIES 64 @@ -69,7 +69,7 @@ struct umap_mount { */ struct umap_node { LIST_ENTRY(umap_node) umap_hash; /* Hash list */ - struct vnode *umap_lowervp; /* Aliased vnode - VREFed once */ + struct vnode *umap_lowervp; /* Aliased vnode - vref'ed once */ struct vnode *umap_vnode; /* Back pointer to vnode/umap_node */ }; diff --git a/sys/vfs/umapfs/umap_subr.c b/sys/vfs/umapfs/umap_subr.c index bab5842acc..78000b7f37 100644 --- a/sys/vfs/umapfs/umap_subr.c +++ b/sys/vfs/umapfs/umap_subr.c @@ -36,7 +36,7 @@ * @(#)umap_subr.c 8.9 (Berkeley) 5/14/95 * * $FreeBSD: src/sys/miscfs/umapfs/umap_subr.c,v 1.19 1999/09/04 11:51:41 bde Exp $ - * $DragonFly: src/sys/vfs/umapfs/Attic/umap_subr.c,v 1.6 2004/03/01 06:33:23 dillon Exp $ + * $DragonFly: src/sys/vfs/umapfs/Attic/umap_subr.c,v 1.7 2004/04/24 04:32:05 drhodus Exp $ */ #include @@ -54,7 +54,7 @@ * Null layer cache: * Each cache entry holds a reference to the target vnode * along with a pointer to the alias vnode. When an - * entry is added the target vnode is VREF'd. When the + * entry is added the target vnode is vref'd. When the * alias is removed the target vnode is vrele'd. */ @@ -155,7 +155,7 @@ umap_node_find(mp, targetvp) * Find hash base, and then search the (two-way) linked * list looking for a umap_node structure which is referencing * the target vnode. If found, the increment the umap_node - * reference count (but NOT the target vnode's VREF counter). + * reference count (but NOT the target vnode's vref counter). */ hd = UMAP_NHASH(targetvp); loop: @@ -236,7 +236,7 @@ umap_node_alloc(mp, lowervp, vpp) *vpp = othervp; return (0); } - VREF(lowervp); /* Extra VREF will be vrele'd in umap_node_create */ + vref(lowervp); /* Extra vref will be vrele'd in umap_node_create */ hd = UMAP_NHASH(lowervp); LIST_INSERT_HEAD(hd, xp, umap_hash); return (0); @@ -264,7 +264,7 @@ umap_node_create(mp, targetvp, newvpp) #ifdef DEBUG vprint("umap_node_create: exists", aliasvp); #endif - /* VREF(aliasvp); */ + /* vref(aliasvp); */ } else { int error; @@ -282,7 +282,7 @@ umap_node_create(mp, targetvp, newvpp) return (error); /* - * aliasvp is already VREF'd by getnewvnode() + * aliasvp is already vref'd by getnewvnode() */ } diff --git a/sys/vfs/umapfs/umap_vfsops.c b/sys/vfs/umapfs/umap_vfsops.c index 65954b2346..f7fbd85c3e 100644 --- a/sys/vfs/umapfs/umap_vfsops.c +++ b/sys/vfs/umapfs/umap_vfsops.c @@ -36,7 +36,7 @@ * @(#)umap_vfsops.c 8.8 (Berkeley) 5/14/95 * * $FreeBSD: src/sys/miscfs/umapfs/umap_vfsops.c,v 1.31.2.2 2001/09/11 09:49:53 kris Exp $ - * $DragonFly: src/sys/vfs/umapfs/Attic/umap_vfsops.c,v 1.9 2004/03/01 06:33:23 dillon Exp $ + * $DragonFly: src/sys/vfs/umapfs/Attic/umap_vfsops.c,v 1.10 2004/04/24 04:32:05 drhodus Exp $ */ /* @@ -306,7 +306,7 @@ umapfs_root(struct mount *mp, struct vnode **vpp) * Return locked reference to root. */ vp = MOUNTTOUMAPMOUNT(mp)->umapm_rootvp; - VREF(vp); + vref(vp); vn_lock(vp, NULL, LK_EXCLUSIVE | LK_RETRY, td); *vpp = vp; return (0); diff --git a/sys/vfs/umapfs/umap_vnops.c b/sys/vfs/umapfs/umap_vnops.c index c1f7f026dd..5d0fc742db 100644 --- a/sys/vfs/umapfs/umap_vnops.c +++ b/sys/vfs/umapfs/umap_vnops.c @@ -35,7 +35,7 @@ * * @(#)umap_vnops.c 8.6 (Berkeley) 5/22/95 * $FreeBSD: src/sys/miscfs/umapfs/umap_vnops.c,v 1.30 1999/08/30 07:08:04 bde Exp $ - * $DragonFly: src/sys/vfs/umapfs/Attic/umap_vnops.c,v 1.6 2004/03/01 06:33:23 dillon Exp $ + * $DragonFly: src/sys/vfs/umapfs/Attic/umap_vnops.c,v 1.7 2004/04/24 04:32:05 drhodus Exp $ */ /* @@ -132,7 +132,7 @@ umap_bypass(ap) old_vps[i] = *this_vp_p; *(vps_p[i]) = UMAPVPTOLOWERVP(*this_vp_p); if (reles & 1) - VREF(*this_vp_p); + vref(*this_vp_p); } } @@ -223,7 +223,7 @@ umap_bypass(ap) /* * Map the possible out-going vpp * (Assumes that the lower layer always returns - * a VREF'ed vpp unless it gets an error.) + * a vref'ed vpp unless it gets an error.) */ if (descp->vdesc_vpp_offset != VDESC_NO_OFFSET && !(descp->vdesc_flags & VDESC_NOMAP_VPP) && diff --git a/sys/vfs/union/union_subr.c b/sys/vfs/union/union_subr.c index ab9a0839d0..248f00bdcb 100644 --- a/sys/vfs/union/union_subr.c +++ b/sys/vfs/union/union_subr.c @@ -36,7 +36,7 @@ * * @(#)union_subr.c 8.20 (Berkeley) 5/20/95 * $FreeBSD: src/sys/miscfs/union/union_subr.c,v 1.43.2.2 2001/12/25 01:44:45 dillon Exp $ - * $DragonFly: src/sys/vfs/union/union_subr.c,v 1.10 2004/03/01 06:33:24 dillon Exp $ + * $DragonFly: src/sys/vfs/union/union_subr.c,v 1.11 2004/04/24 04:32:06 drhodus Exp $ */ #include @@ -364,7 +364,7 @@ union_allocvp(vpp, mp, dvp, upperdvp, cnp, uppervp, lowervp, docache) if (lowervp == NULLVP) { lowervp = um->um_lowervp; if (lowervp != NULLVP) - VREF(lowervp); + vref(lowervp); } vflag = VROOT; } @@ -443,7 +443,7 @@ loop: * our new un is above dvp (we never saw dvp * while moving up the tree). */ - VREF(dvp); + vref(dvp); VOP_UNLOCK(dvp, NULL, 0, td); error = vn_lock(un->un_vnode, NULL, LK_EXCLUSIVE, td); vn_lock(dvp, NULL, LK_EXCLUSIVE | LK_RETRY, td); @@ -577,7 +577,7 @@ loop: un->un_dirvp = upperdvp; un->un_pvp = dvp; /* only parent dir in new allocation */ if (dvp != NULLVP) - VREF(dvp); + vref(dvp); un->un_dircache = 0; un->un_openl = 0; @@ -859,7 +859,7 @@ union_relookup(um, dvp, vpp, cnp, cn, path, pathlen) cn->cn_nameptr = cn->cn_pnbuf; cn->cn_consume = cnp->cn_consume; - VREF(dvp); + vref(dvp); VOP_UNLOCK(dvp, NULL, 0, cnp->cn_td); /* @@ -1062,7 +1062,7 @@ union_vn_create(vpp, un, td) * * If an error occurs, dvp will be returned unlocked and dereferenced. */ - VREF(un->un_dirvp); + vref(un->un_dirvp); error = relookup(un->un_dirvp, &vp, &cn); if (error) return (error); @@ -1196,7 +1196,7 @@ union_dircache_r(vp, vppp, cntp) if (vp->v_op != union_vnodeop_p) { if (vppp) { - VREF(vp); + vref(vp); *(*vppp)++ = vp; if (--(*cntp) == 0) panic("union: dircache table too small"); @@ -1252,7 +1252,7 @@ union_dircache(struct vnode *vp, struct thread *td) /*vn_lock(*vpp, NULL, LK_EXCLUSIVE | LK_RETRY, td);*/ UDEBUG(("ALLOCVP-3 %p ref %d\n", *vpp, (*vpp ? (*vpp)->v_usecount : -99))); - VREF(*vpp); + vref(*vpp); error = union_allocvp(&nvp, vp->v_mount, NULLVP, NULLVP, NULL, *vpp, NULLVP, 0); UDEBUG(("ALLOCVP-3B %p ref %d\n", nvp, (*vpp ? (*vpp)->v_usecount : -99))); if (error) diff --git a/sys/vfs/union/union_vfsops.c b/sys/vfs/union/union_vfsops.c index 691c46cd94..b0cf747c74 100644 --- a/sys/vfs/union/union_vfsops.c +++ b/sys/vfs/union/union_vfsops.c @@ -36,7 +36,7 @@ * * @(#)union_vfsops.c 8.20 (Berkeley) 5/20/95 * $FreeBSD: src/sys/miscfs/union/union_vfsops.c,v 1.39.2.2 2001/10/25 19:18:53 dillon Exp $ - * $DragonFly: src/sys/vfs/union/union_vfsops.c,v 1.10 2004/04/02 12:45:40 hmp Exp $ + * $DragonFly: src/sys/vfs/union/union_vfsops.c,v 1.11 2004/04/24 04:32:06 drhodus Exp $ */ /* @@ -122,7 +122,7 @@ union_mount(mp, path, data, ndp, td) */ lowerrootvp = mp->mnt_vnodecovered; - VREF(lowerrootvp); + vref(lowerrootvp); #if 0 /* @@ -380,9 +380,9 @@ union_root(mp, vpp) UDEBUG(("union_root UPPERVP %p locked = %d\n", um->um_uppervp, VOP_ISLOCKED(um->um_uppervp, NULL))); - VREF(um->um_uppervp); + vref(um->um_uppervp); if (um->um_lowervp) - VREF(um->um_lowervp); + vref(um->um_lowervp); error = union_allocvp(vpp, mp, NULLVP, NULLVP, NULL, um->um_uppervp, um->um_lowervp, 1); diff --git a/sys/vfs/union/union_vnops.c b/sys/vfs/union/union_vnops.c index ab202ef89e..fdb3f84b8a 100644 --- a/sys/vfs/union/union_vnops.c +++ b/sys/vfs/union/union_vnops.c @@ -36,7 +36,7 @@ * * @(#)union_vnops.c 8.32 (Berkeley) 6/23/95 * $FreeBSD: src/sys/miscfs/union/union_vnops.c,v 1.72 1999/12/15 23:02:14 eivind Exp $ - * $DragonFly: src/sys/vfs/union/union_vnops.c,v 1.10 2004/03/01 06:33:24 dillon Exp $ + * $DragonFly: src/sys/vfs/union/union_vnops.c,v 1.11 2004/04/24 04:32:06 drhodus Exp $ */ #include @@ -115,7 +115,7 @@ union_lock_upper(struct union_node *un, struct thread *td) struct vnode *uppervp; if ((uppervp = un->un_uppervp) != NULL) { - VREF(uppervp); + vref(uppervp); vn_lock(uppervp, NULL, LK_EXCLUSIVE | LK_CANRECURSE | LK_RETRY, td); } KASSERT((uppervp == NULL || uppervp->v_usecount > 0), ("uppervp usecount is 0")); @@ -138,7 +138,7 @@ union_lock_other(struct union_node *un, struct thread *td) if (un->un_uppervp != NULL) { vp = union_lock_upper(un, td); } else if ((vp = un->un_lowervp) != NULL) { - VREF(vp); + vref(vp); vn_lock(vp, NULL, LK_EXCLUSIVE | LK_CANRECURSE | LK_RETRY, td); } return(vp); @@ -200,7 +200,7 @@ union_lookup1(udvp, pdvp, vpp, cnp) */ tdvp = dvp; dvp = dvp->v_mount->mnt_vnodecovered; - VREF(dvp); + vref(dvp); vput(tdvp); vn_lock(dvp, NULL, LK_EXCLUSIVE | LK_RETRY, td); } @@ -445,7 +445,7 @@ union_lookup(ap) * not change. On return lowervp doesn't represent anything * to us so we NULL it out. */ - VREF(lowerdvp); + vref(lowerdvp); vn_lock(lowerdvp, NULL, LK_EXCLUSIVE | LK_RETRY, td); lerror = union_lookup1(um->um_lowervp, &lowerdvp, &lowervp, cnp); if (lowerdvp == lowervp) @@ -469,7 +469,7 @@ union_lookup(ap) UDEBUG(("C %p\n", lowerdvp)); if ((cnp->cn_flags & CNP_ISDOTDOT) && dun->un_pvp != NULLVP) { if ((lowervp = LOWERVP(dun->un_pvp)) != NULL) { - VREF(lowervp); + vref(lowervp); vn_lock(lowervp, NULL, LK_EXCLUSIVE | LK_RETRY, td); lerror = 0; } @@ -755,7 +755,7 @@ union_open(ap) tvp = union_lock_upper(un, td); } else { un->un_openl++; - VREF(tvp); + vref(tvp); vn_lock(tvp, NULL, LK_EXCLUSIVE | LK_RETRY, td); tvpisupper = 0; } @@ -1399,7 +1399,7 @@ union_rename(ap) goto bad; } fdvp = un->un_uppervp; - VREF(fdvp); + vref(fdvp); vrele(ap->a_fdvp); } @@ -1454,7 +1454,7 @@ union_rename(ap) if (un->un_lowervp != NULLVP) ap->a_fcnp->cn_flags |= CNP_DOWHITEOUT; fvp = un->un_uppervp; - VREF(fvp); + vref(fvp); vrele(ap->a_fvp); } -- 2.41.0