summaryrefslogtreecommitdiffstats
path: root/sys/fs/coda
diff options
context:
space:
mode:
authordas <das@FreeBSD.org>2005-02-20 23:01:57 +0000
committerdas <das@FreeBSD.org>2005-02-20 23:01:57 +0000
commitf0a7c4fbf8f90b20f546b6374e1d2be702beb9c7 (patch)
treec8a04adb2e8a0005b056e593632461ab66df440d /sys/fs/coda
parent858ff332fa8011a79d62b31a443335ed8b70fe69 (diff)
downloadFreeBSD-src-f0a7c4fbf8f90b20f546b6374e1d2be702beb9c7.zip
FreeBSD-src-f0a7c4fbf8f90b20f546b6374e1d2be702beb9c7.tar.gz
Replace the workaround for a deadlock bug in Coda with a different
workaround that does not rely on vfs_start().
Diffstat (limited to 'sys/fs/coda')
-rw-r--r--sys/fs/coda/coda_vfsops.c19
-rw-r--r--sys/fs/coda/coda_vfsops.h1
2 files changed, 4 insertions, 16 deletions
diff --git a/sys/fs/coda/coda_vfsops.c b/sys/fs/coda/coda_vfsops.c
index 5e7c250..5ba4395 100644
--- a/sys/fs/coda/coda_vfsops.c
+++ b/sys/fs/coda/coda_vfsops.c
@@ -290,8 +290,8 @@ coda_root(vfsp, vpp, td)
* on to Venus if the root vnode is the dummy we installed in
* coda_omount() with all c_fid members zeroed.
*
- * XXX In addition, if we are called between coda_omount() and
- * coda_start(), we assume that the request is from vfs_omount()
+ * XXX In addition, we assume that the first call to coda_root()
+ * is from vfs_omount()
* (before the call to checkdirs()) and return the dummy root
* node to avoid a deadlock. This bug is fixed in the Coda CVS
* repository but not in any released versions as of 6 Mar 2003.
@@ -300,6 +300,8 @@ coda_root(vfsp, vpp, td)
sizeof(CodaFid)) != 0 || mi->mi_started == 0)
{ /* Found valid root. */
*vpp = mi->mi_rootvp;
+ mi->mi_started = 1;
+
/* On Mach, this is vref. On NetBSD, VOP_LOCK */
#if 1
vref(*vpp);
@@ -365,18 +367,6 @@ coda_root(vfsp, vpp, td)
return(error);
}
-int
-coda_start(mp, flags, td)
- struct mount *mp;
- int flags;
- struct thread *td;
-{
-
- /* XXX See coda_root(). */
- vftomi(mp)->mi_started = 1;
- return (0);
-}
-
/*
* Get filesystem statistics.
*/
@@ -531,7 +521,6 @@ struct mount *devtomp(dev)
struct vfsops coda_vfsops = {
.vfs_mount = coda_mount,
.vfs_root = coda_root,
- .vfs_start = coda_start,
.vfs_statfs = coda_nb_statfs,
.vfs_sync = coda_sync,
.vfs_unmount = coda_unmount,
diff --git a/sys/fs/coda/coda_vfsops.h b/sys/fs/coda/coda_vfsops.h
index 53b55d4..8a66545 100644
--- a/sys/fs/coda/coda_vfsops.h
+++ b/sys/fs/coda/coda_vfsops.h
@@ -51,7 +51,6 @@ int coda_fhtovp(struct mount *, struct fid *, struct mbuf *, struct vnode **,
int *, struct ucred **);
vfs_mount_t coda_mount;
-vfs_start_t coda_start;
vfs_unmount_t coda_unmount;
vfs_root_t coda_root;
vfs_quotactl_t coda_quotactl;
OpenPOWER on IntegriCloud