summaryrefslogtreecommitdiffstats
path: root/sys/kern/vfs_vnops.c
diff options
context:
space:
mode:
authorkib <kib@FreeBSD.org>2008-09-16 11:09:26 +0000
committerkib <kib@FreeBSD.org>2008-09-16 11:09:26 +0000
commit039c5da1b25fe16e767d26bf96a871642f599a7f (patch)
tree3b5e95bdb6db8b07c4b422cc9f728b3869de1c44 /sys/kern/vfs_vnops.c
parentad287e3d61bd9ac5dc16f705f511e471510755c4 (diff)
downloadFreeBSD-src-039c5da1b25fe16e767d26bf96a871642f599a7f.zip
FreeBSD-src-039c5da1b25fe16e767d26bf96a871642f599a7f.tar.gz
Garbage-collect vn_write_suspend_wait().
Suggested and reviewed by: tegge Tested by: pho MFC after: 1 month
Diffstat (limited to 'sys/kern/vfs_vnops.c')
-rw-r--r--sys/kern/vfs_vnops.c50
1 files changed, 0 insertions, 50 deletions
diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c
index 6e7c5a0..58863f4 100644
--- a/sys/kern/vfs_vnops.c
+++ b/sys/kern/vfs_vnops.c
@@ -974,56 +974,6 @@ unlock:
* time, these operations are halted until the suspension is over.
*/
int
-vn_write_suspend_wait(vp, mp, flags)
- struct vnode *vp;
- struct mount *mp;
- int flags;
-{
- int error;
-
- if (vp != NULL) {
- if ((error = VOP_GETWRITEMOUNT(vp, &mp)) != 0) {
- if (error != EOPNOTSUPP)
- return (error);
- return (0);
- }
- }
- /*
- * If we are not suspended or have not yet reached suspended
- * mode, then let the operation proceed.
- */
- if (mp == NULL)
- return (0);
- MNT_ILOCK(mp);
- if (vp == NULL)
- MNT_REF(mp);
- if ((mp->mnt_kern_flag & MNTK_SUSPENDED) == 0) {
- MNT_REL(mp);
- MNT_IUNLOCK(mp);
- return (0);
- }
- if (flags & V_NOWAIT) {
- MNT_REL(mp);
- MNT_IUNLOCK(mp);
- return (EWOULDBLOCK);
- }
- /*
- * Wait for the suspension to finish.
- */
- error = msleep(&mp->mnt_flag, MNT_MTX(mp),
- (PUSER - 1) | (flags & PCATCH) | PDROP, "suspfs", 0);
- vfs_rel(mp);
- return (error);
-}
-
-/*
- * Secondary suspension. Used by operations such as vop_inactive
- * routines that are needed by the higher level functions. These
- * are allowed to proceed until all the higher level functions have
- * completed (indicated by mnt_writeopcount dropping to zero). At that
- * time, these operations are halted until the suspension is over.
- */
-int
vn_start_secondary_write(vp, mpp, flags)
struct vnode *vp;
struct mount **mpp;
OpenPOWER on IntegriCloud