summaryrefslogtreecommitdiffstats
path: root/sys/fs
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2005-01-24 23:53:54 +0000
committerphk <phk@FreeBSD.org>2005-01-24 23:53:54 +0000
commit716e67e4292c3e3a48c81b109049e9cd7c14295a (patch)
treee520ce1bbad4ddf753d1d89b02119844f76cc362 /sys/fs
parent3aef1b3f6e28eb52883baffa23736c0c07437526 (diff)
downloadFreeBSD-src-716e67e4292c3e3a48c81b109049e9cd7c14295a.zip
FreeBSD-src-716e67e4292c3e3a48c81b109049e9cd7c14295a.tar.gz
Don't call VOP_CREATEVOBJECT(), it's the responsibility of the
filesystem which owns the vnode.
Diffstat (limited to 'sys/fs')
-rw-r--r--sys/fs/coda/coda_vnops.c26
-rw-r--r--sys/fs/unionfs/union_subr.c10
-rw-r--r--sys/fs/unionfs/union_vnops.c6
3 files changed, 0 insertions, 42 deletions
diff --git a/sys/fs/coda/coda_vnops.c b/sys/fs/coda/coda_vnops.c
index 9509115..30f62d3 100644
--- a/sys/fs/coda/coda_vnops.c
+++ b/sys/fs/coda/coda_vnops.c
@@ -266,13 +266,6 @@ coda_open(struct vop_open_args *ap)
return (error);
}
/* grab (above) does this when it calls newvnode unless it's in the cache*/
- if (vp->v_type == VREG) {
- error = VOP_CREATEVOBJECT(vp, cred, td);
- if (error != 0) {
- printf("coda_open: VOP_CREATEVOBJECT() returns %d\n", error);
- vput(vp);
- }
- }
return(error);
}
@@ -431,17 +424,6 @@ printf("coda_rdwr: Internally Opening %p\n", vp);
printf("coda_rdwr: VOP_OPEN on container failed %d\n", error);
return (error);
}
- if (vp->v_type == VREG) {
- error = VOP_CREATEVOBJECT(vp, cred, td);
- if (error != 0) {
- printf("coda_rdwr: VOP_CREATEVOBJECT() returns %d\n", error);
- vput(vp);
- }
- }
- if (error) {
- MARK_INT_FAIL(CODA_RDWR_STATS);
- return(error);
- }
cfvp = cp->c_ovp;
}
}
@@ -1562,14 +1544,6 @@ printf("coda_readdir: Internally Opening %p\n", vp);
printf("coda_readdir: VOP_OPEN on container failed %d\n", error);
return (error);
}
- if (vp->v_type == VREG) {
- error = VOP_CREATEVOBJECT(vp, cred, td);
- if (error != 0) {
- printf("coda_readdir: VOP_CREATEVOBJECT() returns %d\n", error);
- vput(vp);
- }
- }
- if (error) return(error);
}
/* Have UFS handle the call. */
diff --git a/sys/fs/unionfs/union_subr.c b/sys/fs/unionfs/union_subr.c
index 78a469b..6cc5e62 100644
--- a/sys/fs/unionfs/union_subr.c
+++ b/sys/fs/unionfs/union_subr.c
@@ -781,8 +781,6 @@ union_copyup(un, docopy, cred, td)
*/
vn_lock(lvp, LK_EXCLUSIVE | LK_RETRY, td);
error = VOP_OPEN(lvp, FREAD, cred, td, -1);
- if (error == 0 && vn_canvmio(lvp) == TRUE)
- error = VOP_CREATEVOBJECT(lvp, cred, td);
if (error == 0) {
error = union_copyfile(lvp, uvp, cred, td);
VOP_UNLOCK(lvp, 0, td);
@@ -813,10 +811,6 @@ union_copyup(un, docopy, cred, td)
(void) VOP_CLOSE(lvp, FREAD, cred, td);
(void) VOP_OPEN(uvp, FREAD, cred, td, -1);
}
- if (un->un_openl) {
- if (vn_canvmio(uvp) == TRUE)
- error = VOP_CREATEVOBJECT(uvp, cred, td);
- }
un->un_openl = 0;
}
@@ -1127,8 +1121,6 @@ union_vn_create(vpp, un, td)
return (error);
error = VOP_OPEN(vp, fmode, cred, td, -1);
- if (error == 0 && vn_canvmio(vp) == TRUE)
- error = VOP_CREATEVOBJECT(vp, cred, td);
if (error) {
vput(vp);
return (error);
@@ -1330,8 +1322,6 @@ union_dircheck(struct thread *td, struct vnode **vp, struct file *fp)
if (lvp != NULLVP) {
error = VOP_OPEN(lvp, FREAD, fp->f_cred, td, -1);
- if (error == 0 && vn_canvmio(lvp) == TRUE)
- error = VOP_CREATEVOBJECT(lvp, fp->f_cred, td);
if (error) {
vput(lvp);
return (error);
diff --git a/sys/fs/unionfs/union_vnops.c b/sys/fs/unionfs/union_vnops.c
index 8094b06..a1f3988 100644
--- a/sys/fs/unionfs/union_vnops.c
+++ b/sys/fs/unionfs/union_vnops.c
@@ -783,12 +783,6 @@ union_open(ap)
error = VOP_OPEN(tvp, mode, cred, td, -1);
/*
- * This is absolutely necessary or UFS will blow up.
- */
- if (error == 0 && vn_canvmio(tvp) == TRUE)
- error = VOP_CREATEVOBJECT(tvp, cred, td);
-
- /*
* Release any locks held.
*/
if (tvpisupper) {
OpenPOWER on IntegriCloud