diff options
author | attilio <attilio@FreeBSD.org> | 2008-08-31 14:26:08 +0000 |
---|---|---|
committer | attilio <attilio@FreeBSD.org> | 2008-08-31 14:26:08 +0000 |
commit | e2ca413d09b408b7f5caff24c9c36ddb1c43dc7c (patch) | |
tree | 904524119c5e2a5d0942f492871aaf2f60b15b70 /sys | |
parent | 2d23f13f7f4cdaadb7247c2f0597e503d6035508 (diff) | |
download | FreeBSD-src-e2ca413d09b408b7f5caff24c9c36ddb1c43dc7c.zip FreeBSD-src-e2ca413d09b408b7f5caff24c9c36ddb1c43dc7c.tar.gz |
Decontextualize vfs_busy(), vfs_unbusy() and vfs_mount_alloc() functions.
Manpages are updated accordingly.
Tested by: Diego Sardina <siarodx at gmail dot com>
Diffstat (limited to 'sys')
-rw-r--r-- | sys/cddl/compat/opensolaris/kern/opensolaris_vfs.c | 6 | ||||
-rw-r--r-- | sys/geom/journal/g_journal.c | 9 | ||||
-rw-r--r-- | sys/gnu/fs/ext2fs/ext2_vfsops.c | 4 | ||||
-rw-r--r-- | sys/kern/vfs_lookup.c | 4 | ||||
-rw-r--r-- | sys/kern/vfs_mount.c | 28 | ||||
-rw-r--r-- | sys/kern/vfs_subr.c | 26 | ||||
-rw-r--r-- | sys/kern/vfs_syscalls.c | 20 | ||||
-rw-r--r-- | sys/nfsclient/nfs_vfsops.c | 6 | ||||
-rw-r--r-- | sys/sys/mount.h | 6 | ||||
-rw-r--r-- | sys/ufs/ffs/ffs_softdep.c | 4 | ||||
-rw-r--r-- | sys/ufs/ufs/ufs_vfsops.c | 4 |
11 files changed, 55 insertions, 62 deletions
diff --git a/sys/cddl/compat/opensolaris/kern/opensolaris_vfs.c b/sys/cddl/compat/opensolaris/kern/opensolaris_vfs.c index 6360a72..e9120ee 100644 --- a/sys/cddl/compat/opensolaris/kern/opensolaris_vfs.c +++ b/sys/cddl/compat/opensolaris/kern/opensolaris_vfs.c @@ -193,7 +193,7 @@ domount(kthread_t *td, vnode_t *vp, const char *fstype, char *fspath, * Allocate and initialize the filesystem. */ vn_lock(vp, LK_SHARED | LK_RETRY); - mp = vfs_mount_alloc(vp, vfsp, fspath, td); + mp = vfs_mount_alloc(vp, vfsp, fspath, td->td_ucred); VOP_UNLOCK(vp, 0); mp->mnt_optnew = NULL; @@ -263,7 +263,7 @@ domount(kthread_t *td, vnode_t *vp, const char *fstype, char *fspath, VOP_UNLOCK(vp, 0); if ((mp->mnt_flag & MNT_RDONLY) == 0) error = vfs_allocate_syncvnode(mp); - vfs_unbusy(mp, td); + vfs_unbusy(mp); if (error) vrele(vp); else @@ -273,7 +273,7 @@ domount(kthread_t *td, vnode_t *vp, const char *fstype, char *fspath, vp->v_iflag &= ~VI_MOUNT; VI_UNLOCK(vp); VOP_UNLOCK(vp, 0); - vfs_unbusy(mp, td); + vfs_unbusy(mp); vfs_mount_destroy(mp); } return (error); diff --git a/sys/geom/journal/g_journal.c b/sys/geom/journal/g_journal.c index 7c170bf..0d86559 100644 --- a/sys/geom/journal/g_journal.c +++ b/sys/geom/journal/g_journal.c @@ -2843,7 +2843,7 @@ g_journal_switch_wait(struct g_journal_softc *sc) } static void -g_journal_do_switch(struct g_class *classp, struct thread *td) +g_journal_do_switch(struct g_class *classp) { struct g_journal_softc *sc; const struct g_journal_desc *desc; @@ -2879,7 +2879,7 @@ g_journal_do_switch(struct g_class *classp, struct thread *td) desc = g_journal_find_desc(mp->mnt_stat.f_fstypename); if (desc == NULL) continue; - if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx, td)) + if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx)) continue; /* mtx_unlock(&mountlist_mtx) was done inside vfs_busy() */ @@ -2973,7 +2973,7 @@ g_journal_do_switch(struct g_class *classp, struct thread *td) vfs_write_resume(mp); next: mtx_lock(&mountlist_mtx); - vfs_unbusy(mp, td); + vfs_unbusy(mp); } mtx_unlock(&mountlist_mtx); @@ -3011,7 +3011,6 @@ next: static void g_journal_switcher(void *arg) { - struct thread *td = curthread; struct g_class *mp; struct bintime bt; int error; @@ -3033,7 +3032,7 @@ g_journal_switcher(void *arg) g_journal_cache_limit); } GJ_TIMER_START(1, &bt); - g_journal_do_switch(mp, td); + g_journal_do_switch(mp); GJ_TIMER_STOP(1, &bt, "Entire switch time"); if (g_journal_sync_requested > 0) { g_journal_sync_requested = 0; diff --git a/sys/gnu/fs/ext2fs/ext2_vfsops.c b/sys/gnu/fs/ext2fs/ext2_vfsops.c index cf0bb51..ebcb476 100644 --- a/sys/gnu/fs/ext2fs/ext2_vfsops.c +++ b/sys/gnu/fs/ext2fs/ext2_vfsops.c @@ -171,10 +171,10 @@ ext2_mount(mp, td) flags = WRITECLOSE; if (mp->mnt_flag & MNT_FORCE) flags |= FORCECLOSE; - if (vfs_busy(mp, LK_NOWAIT, 0, td)) + if (vfs_busy(mp, LK_NOWAIT, 0)) return (EBUSY); error = ext2_flushfiles(mp, flags, td); - vfs_unbusy(mp, td); + vfs_unbusy(mp); if (!error && fs->s_wasvalid) { fs->s_es->s_state |= EXT2_VALID_FS; ext2_sbupdate(ump, MNT_WAIT); diff --git a/sys/kern/vfs_lookup.c b/sys/kern/vfs_lookup.c index 1b295fc..8adb68e 100644 --- a/sys/kern/vfs_lookup.c +++ b/sys/kern/vfs_lookup.c @@ -688,7 +688,7 @@ unionlookup: */ while (dp->v_type == VDIR && (mp = dp->v_mountedhere) && (cnp->cn_flags & NOCROSSMOUNT) == 0) { - if (vfs_busy(mp, 0, 0, td)) + if (vfs_busy(mp, 0, 0)) continue; vput(dp); VFS_UNLOCK_GIANT(vfslocked); @@ -702,7 +702,7 @@ unionlookup: vref(vp_crossmp); ndp->ni_dvp = vp_crossmp; error = VFS_ROOT(mp, compute_cn_lkflags(mp, cnp->cn_lkflags), &tdp, td); - vfs_unbusy(mp, td); + vfs_unbusy(mp); if (vn_lock(vp_crossmp, LK_SHARED | LK_NOWAIT)) panic("vp_crossmp exclusively locked or reclaimed"); if (error) { diff --git a/sys/kern/vfs_mount.c b/sys/kern/vfs_mount.c index b25ba3b..8b2df8e 100644 --- a/sys/kern/vfs_mount.c +++ b/sys/kern/vfs_mount.c @@ -472,8 +472,8 @@ mount_fini(void *mem, int size) * Allocate and initialize the mount point struct. */ struct mount * -vfs_mount_alloc(struct vnode *vp, struct vfsconf *vfsp, - const char *fspath, struct thread *td) +vfs_mount_alloc(struct vnode *vp, struct vfsconf *vfsp, const char *fspath, + struct ucred *cred) { struct mount *mp; @@ -483,7 +483,7 @@ vfs_mount_alloc(struct vnode *vp, struct vfsconf *vfsp, TAILQ_INIT(&mp->mnt_nvnodelist); mp->mnt_nvnodelistsize = 0; mp->mnt_ref = 0; - (void) vfs_busy(mp, LK_NOWAIT, 0, td); + (void) vfs_busy(mp, LK_NOWAIT, 0); mp->mnt_op = vfsp->vfc_vfsops; mp->mnt_vfc = vfsp; vfsp->vfc_refcount++; /* XXX Unlocked */ @@ -491,13 +491,13 @@ vfs_mount_alloc(struct vnode *vp, struct vfsconf *vfsp, mp->mnt_gen++; strlcpy(mp->mnt_stat.f_fstypename, vfsp->vfc_name, MFSNAMELEN); mp->mnt_vnodecovered = vp; - mp->mnt_cred = crdup(td->td_ucred); - mp->mnt_stat.f_owner = td->td_ucred->cr_uid; + mp->mnt_cred = crdup(cred); + mp->mnt_stat.f_owner = cred->cr_uid; strlcpy(mp->mnt_stat.f_mntonname, fspath, MNAMELEN); mp->mnt_iosize_max = DFLTPHYS; #ifdef MAC mac_mount_init(mp); - mac_mount_create(td->td_ucred, mp); + mac_mount_create(cred, mp); #endif arc4rand(&mp->mnt_hashseed, sizeof mp->mnt_hashseed, 0); return (mp); @@ -932,7 +932,7 @@ vfs_domount( vput(vp); return (error); } - if (vfs_busy(mp, LK_NOWAIT, 0, td)) { + if (vfs_busy(mp, LK_NOWAIT, 0)) { vput(vp); return (EBUSY); } @@ -940,7 +940,7 @@ vfs_domount( if ((vp->v_iflag & VI_MOUNT) != 0 || vp->v_mountedhere != NULL) { VI_UNLOCK(vp); - vfs_unbusy(mp, td); + vfs_unbusy(mp); vput(vp); return (EBUSY); } @@ -993,7 +993,7 @@ vfs_domount( /* * Allocate and initialize the filesystem. */ - mp = vfs_mount_alloc(vp, vfsp, fspath, td); + mp = vfs_mount_alloc(vp, vfsp, fspath, td->td_ucred); VOP_UNLOCK(vp, 0); /* XXXMAC: pass to vfs_mount_alloc? */ @@ -1059,7 +1059,7 @@ vfs_domount( vrele(mp->mnt_syncer); mp->mnt_syncer = NULL; } - vfs_unbusy(mp, td); + vfs_unbusy(mp); VI_LOCK(vp); vp->v_iflag &= ~VI_MOUNT; VI_UNLOCK(vp); @@ -1095,14 +1095,14 @@ vfs_domount( VOP_UNLOCK(vp, 0); if ((mp->mnt_flag & MNT_RDONLY) == 0) error = vfs_allocate_syncvnode(mp); - vfs_unbusy(mp, td); + vfs_unbusy(mp); if (error) vrele(vp); } else { VI_LOCK(vp); vp->v_iflag &= ~VI_MOUNT; VI_UNLOCK(vp); - vfs_unbusy(mp, td); + vfs_unbusy(mp); vfs_mount_destroy(mp); vput(vp); } @@ -1514,7 +1514,7 @@ devfs_first(void) if (vfsp == NULL) return; - mp = vfs_mount_alloc(NULLVP, vfsp, "/dev", td); + mp = vfs_mount_alloc(NULLVP, vfsp, "/dev", td->td_ucred); error = VFS_MOUNT(mp, td); KASSERT(error == 0, ("VFS_MOUNT(devfs) failed %d", error)); @@ -1589,7 +1589,7 @@ devfs_fixup(struct thread *td) mtx_unlock(&mountlist_mtx); VOP_UNLOCK(vp, 0); vput(dvp); - vfs_unbusy(mp, td); + vfs_unbusy(mp); /* Unlink the no longer needed /dev/dev -> / symlink */ kern_unlink(td, "/dev/dev", UIO_SYSSPACE); diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index d097d13..ce404ff 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -338,8 +338,7 @@ SYSINIT(vfs, SI_SUB_VFS, SI_ORDER_FIRST, vntblinit, NULL); * unmounting. Interlock is not released on failure. */ int -vfs_busy(struct mount *mp, int flags, struct mtx *interlkp, - struct thread *td) +vfs_busy(struct mount *mp, int flags, struct mtx *interlkp) { int lkflags; @@ -379,7 +378,7 @@ vfs_busy(struct mount *mp, int flags, struct mtx *interlkp, * Free a busy filesystem. */ void -vfs_unbusy(struct mount *mp, struct thread *td) +vfs_unbusy(struct mount *mp) { lockmgr(&mp->mnt_lock, LK_RELEASE, NULL); @@ -573,7 +572,6 @@ vattr_null(struct vattr *vap) static int vlrureclaim(struct mount *mp) { - struct thread *td; struct vnode *vp; int done; int trigger; @@ -592,7 +590,6 @@ vlrureclaim(struct mount *mp) usevnodes = 1; trigger = cnt.v_page_count * 2 / usevnodes; done = 0; - td = curthread; vn_start_write(NULL, &mp, V_WAIT); MNT_ILOCK(mp); count = mp->mnt_nvnodelistsize / 10 + 1; @@ -727,7 +724,6 @@ vnlru_proc(void) struct mount *mp, *nmp; int done; struct proc *p = vnlruproc; - struct thread *td = curthread; EVENTHANDLER_REGISTER(shutdown_pre_sync, kproc_shutdown, p, SHUTDOWN_PRI_FIRST); @@ -751,7 +747,7 @@ vnlru_proc(void) mtx_lock(&mountlist_mtx); for (mp = TAILQ_FIRST(&mountlist); mp != NULL; mp = nmp) { int vfsunlocked; - if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx, td)) { + if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx)) { nmp = TAILQ_NEXT(mp, mnt_list); continue; } @@ -765,7 +761,7 @@ vnlru_proc(void) mtx_lock(&Giant); mtx_lock(&mountlist_mtx); nmp = TAILQ_NEXT(mp, mnt_list); - vfs_unbusy(mp, td); + vfs_unbusy(mp); } mtx_unlock(&mountlist_mtx); if (done == 0) { @@ -2988,7 +2984,6 @@ static int sysctl_vnode(SYSCTL_HANDLER_ARGS) { struct xvnode *xvn; - struct thread *td = req->td; struct mount *mp; struct vnode *vp; int error, len, n; @@ -3009,7 +3004,7 @@ sysctl_vnode(SYSCTL_HANDLER_ARGS) n = 0; mtx_lock(&mountlist_mtx); TAILQ_FOREACH(mp, &mountlist, mnt_list) { - if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx, td)) + if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx)) continue; MNT_ILOCK(mp); TAILQ_FOREACH(vp, &mp->mnt_nvnodelist, v_nmntvnodes) { @@ -3060,7 +3055,7 @@ sysctl_vnode(SYSCTL_HANDLER_ARGS) } MNT_IUNLOCK(mp); mtx_lock(&mountlist_mtx); - vfs_unbusy(mp, td); + vfs_unbusy(mp); if (n == len) break; } @@ -3337,7 +3332,6 @@ sync_fsync(struct vop_fsync_args *ap) { struct vnode *syncvp = ap->a_vp; struct mount *mp = syncvp->v_mount; - struct thread *td = ap->a_td; int error; struct bufobj *bo; @@ -3360,12 +3354,12 @@ sync_fsync(struct vop_fsync_args *ap) * not already on the sync list. */ mtx_lock(&mountlist_mtx); - if (vfs_busy(mp, LK_EXCLUSIVE | LK_NOWAIT, &mountlist_mtx, td) != 0) { + if (vfs_busy(mp, LK_EXCLUSIVE | LK_NOWAIT, &mountlist_mtx) != 0) { mtx_unlock(&mountlist_mtx); return (0); } if (vn_start_write(NULL, &mp, V_NOWAIT) != 0) { - vfs_unbusy(mp, td); + vfs_unbusy(mp); return (0); } MNT_ILOCK(mp); @@ -3373,14 +3367,14 @@ sync_fsync(struct vop_fsync_args *ap) mp->mnt_kern_flag &= ~MNTK_ASYNC; MNT_IUNLOCK(mp); vfs_msync(mp, MNT_NOWAIT); - error = VFS_SYNC(mp, MNT_LAZY, td); + error = VFS_SYNC(mp, MNT_LAZY, ap->a_td); MNT_ILOCK(mp); mp->mnt_noasync--; if ((mp->mnt_flag & MNT_ASYNC) != 0 && mp->mnt_noasync == 0) mp->mnt_kern_flag |= MNTK_ASYNC; MNT_IUNLOCK(mp); vn_finished_write(mp); - vfs_unbusy(mp, td); + vfs_unbusy(mp); return (error); } diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index ee66315..5a3ba14 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -124,7 +124,7 @@ sync(td, uap) mtx_lock(&mountlist_mtx); for (mp = TAILQ_FIRST(&mountlist); mp != NULL; mp = nmp) { - if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx, td)) { + if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx)) { nmp = TAILQ_NEXT(mp, mnt_list); continue; } @@ -148,7 +148,7 @@ sync(td, uap) VFS_UNLOCK_GIANT(vfslocked); mtx_lock(&mountlist_mtx); nmp = TAILQ_NEXT(mp, mnt_list); - vfs_unbusy(mp, td); + vfs_unbusy(mp); } mtx_unlock(&mountlist_mtx); return (0); @@ -197,14 +197,14 @@ quotactl(td, uap) vfslocked = NDHASGIANT(&nd); NDFREE(&nd, NDF_ONLY_PNBUF); mp = nd.ni_vp->v_mount; - if ((error = vfs_busy(mp, 0, NULL, td))) { + if ((error = vfs_busy(mp, 0, NULL))) { vrele(nd.ni_vp); VFS_UNLOCK_GIANT(vfslocked); return (error); } vrele(nd.ni_vp); error = VFS_QUOTACTL(mp, uap->cmd, uap->uid, uap->arg, td); - vfs_unbusy(mp, td); + vfs_unbusy(mp); VFS_UNLOCK_GIANT(vfslocked); return (error); } @@ -479,7 +479,7 @@ kern_getfsstat(struct thread *td, struct statfs **buf, size_t bufsize, continue; } #endif - if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx, td)) { + if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx)) { nmp = TAILQ_NEXT(mp, mnt_list); continue; } @@ -504,7 +504,7 @@ kern_getfsstat(struct thread *td, struct statfs **buf, size_t bufsize, VFS_UNLOCK_GIANT(vfslocked); mtx_lock(&mountlist_mtx); nmp = TAILQ_NEXT(mp, mnt_list); - vfs_unbusy(mp, td); + vfs_unbusy(mp); continue; } if (priv_check(td, PRIV_VFS_GENERATION)) { @@ -518,7 +518,7 @@ kern_getfsstat(struct thread *td, struct statfs **buf, size_t bufsize, else /* if (bufseg == UIO_USERSPACE) */ { error = copyout(sp, sfsp, sizeof(*sp)); if (error) { - vfs_unbusy(mp, td); + vfs_unbusy(mp); VFS_UNLOCK_GIANT(vfslocked); return (error); } @@ -529,7 +529,7 @@ kern_getfsstat(struct thread *td, struct statfs **buf, size_t bufsize, count++; mtx_lock(&mountlist_mtx); nmp = TAILQ_NEXT(mp, mnt_list); - vfs_unbusy(mp, td); + vfs_unbusy(mp); } mtx_unlock(&mountlist_mtx); if (sfsp && count > maxcount) @@ -741,11 +741,11 @@ fchdir(td, uap) error = change_dir(vp, td); while (!error && (mp = vp->v_mountedhere) != NULL) { int tvfslocked; - if (vfs_busy(mp, 0, 0, td)) + if (vfs_busy(mp, 0, 0)) continue; tvfslocked = VFS_LOCK_GIANT(mp); error = VFS_ROOT(mp, LK_EXCLUSIVE, &tdp, td); - vfs_unbusy(mp, td); + vfs_unbusy(mp); if (error) { VFS_UNLOCK_GIANT(tvfslocked); break; diff --git a/sys/nfsclient/nfs_vfsops.c b/sys/nfsclient/nfs_vfsops.c index 6b6557f..a653a0e 100644 --- a/sys/nfsclient/nfs_vfsops.c +++ b/sys/nfsclient/nfs_vfsops.c @@ -258,12 +258,12 @@ nfs_statfs(struct mount *mp, struct statfs *sbp, struct thread *td) #ifndef nolint sfp = NULL; #endif - error = vfs_busy(mp, LK_NOWAIT, NULL, td); + error = vfs_busy(mp, LK_NOWAIT, NULL); if (error) return (error); error = nfs_nget(mp, (nfsfh_t *)nmp->nm_fh, nmp->nm_fhsize, &np, LK_EXCLUSIVE); if (error) { - vfs_unbusy(mp, td); + vfs_unbusy(mp); return (error); } vp = NFSTOV(np); @@ -313,7 +313,7 @@ nfs_statfs(struct mount *mp, struct statfs *sbp, struct thread *td) m_freem(mrep); nfsmout: vput(vp); - vfs_unbusy(mp, td); + vfs_unbusy(mp); return (error); } diff --git a/sys/sys/mount.h b/sys/sys/mount.h index f74ccba..7e9534e 100644 --- a/sys/sys/mount.h +++ b/sys/sys/mount.h @@ -680,7 +680,7 @@ int vfs_scanopt(struct vfsoptlist *opts, const char *name, const char *fmt, ...) int vfs_setpublicfs /* set publicly exported fs */ (struct mount *, struct netexport *, struct export_args *); void vfs_msync(struct mount *, int); -int vfs_busy(struct mount *, int, struct mtx *, struct thread *); +int vfs_busy(struct mount *, int, struct mtx *); int vfs_export /* process mount export info */ (struct mount *, struct export_args *); int vfs_allocate_syncvnode(struct mount *); @@ -694,9 +694,9 @@ void vfs_mountedfrom(struct mount *, const char *from); void vfs_ref(struct mount *); void vfs_rel(struct mount *); struct mount *vfs_mount_alloc(struct vnode *, struct vfsconf *, const char *, - struct thread *); + struct ucred *); int vfs_suser(struct mount *, struct thread *); -void vfs_unbusy(struct mount *, struct thread *); +void vfs_unbusy(struct mount *); void vfs_unmountall(void); extern TAILQ_HEAD(mntlist, mount) mountlist; /* mounted filesystem list */ extern struct mtx mountlist_mtx; diff --git a/sys/ufs/ffs/ffs_softdep.c b/sys/ufs/ffs/ffs_softdep.c index 2475bb3..4244588 100644 --- a/sys/ufs/ffs/ffs_softdep.c +++ b/sys/ufs/ffs/ffs_softdep.c @@ -742,7 +742,7 @@ softdep_flush(void) nmp = TAILQ_NEXT(mp, mnt_list); if ((mp->mnt_flag & MNT_SOFTDEP) == 0) continue; - if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx, td)) + if (vfs_busy(mp, LK_NOWAIT, &mountlist_mtx)) continue; vfslocked = VFS_LOCK_GIANT(mp); softdep_process_worklist(mp, 0); @@ -752,7 +752,7 @@ softdep_flush(void) VFS_UNLOCK_GIANT(vfslocked); mtx_lock(&mountlist_mtx); nmp = TAILQ_NEXT(mp, mnt_list); - vfs_unbusy(mp, td); + vfs_unbusy(mp); } mtx_unlock(&mountlist_mtx); if (remaining) diff --git a/sys/ufs/ufs/ufs_vfsops.c b/sys/ufs/ufs/ufs_vfsops.c index 1280cdb..c983164 100644 --- a/sys/ufs/ufs/ufs_vfsops.c +++ b/sys/ufs/ufs/ufs_vfsops.c @@ -118,7 +118,7 @@ ufs_quotactl(mp, cmds, id, arg, td) if ((u_int)type >= MAXQUOTAS) return (EINVAL); - if (vfs_busy(mp, LK_NOWAIT, 0, td)) + if (vfs_busy(mp, LK_NOWAIT, 0)) return (0); switch (cmd) { @@ -150,7 +150,7 @@ ufs_quotactl(mp, cmds, id, arg, td) error = EINVAL; break; } - vfs_unbusy(mp, td); + vfs_unbusy(mp); return (error); #endif } |