diff options
| author | Robert Watson <rwatson@FreeBSD.org> | 2009-04-10 10:52:19 +0000 |
|---|---|---|
| committer | Robert Watson <rwatson@FreeBSD.org> | 2009-04-10 10:52:19 +0000 |
| commit | 885868cd8f34658a50b376ff06df3c4990666c17 (patch) | |
| tree | 60ec81c960bc903ee02261b0b6fa507c405c3d75 /sys/fs/unionfs | |
| parent | 3f54086eba4a1df9981cee3e8f94a3b2b652c205 (diff) | |
Notes
Diffstat (limited to 'sys/fs/unionfs')
| -rw-r--r-- | sys/fs/unionfs/union_subr.c | 14 | ||||
| -rw-r--r-- | sys/fs/unionfs/union_vnops.c | 24 |
2 files changed, 2 insertions, 36 deletions
diff --git a/sys/fs/unionfs/union_subr.c b/sys/fs/unionfs/union_subr.c index beaef2f94ec6..69165e353b23 100644 --- a/sys/fs/unionfs/union_subr.c +++ b/sys/fs/unionfs/union_subr.c @@ -805,10 +805,6 @@ unionfs_mkshadowdir(struct unionfs_mount *ump, struct vnode *udvp, if ((error = vn_start_write(udvp, &mp, V_WAIT | PCATCH))) goto unionfs_mkshadowdir_free_out; - if ((error = VOP_LEASE(udvp, td, cn.cn_cred, LEASE_WRITE))) { - vn_finished_write(mp); - goto unionfs_mkshadowdir_free_out; - } unionfs_create_uppervattr_core(ump, &lva, &va, td); error = VOP_MKDIR(udvp, &uvp, &cn, &va); @@ -874,8 +870,7 @@ unionfs_mkwhiteout(struct vnode *dvp, struct componentname *cnp, if ((error = vn_start_write(dvp, &mp, V_WAIT | PCATCH))) goto unionfs_mkwhiteout_free_out; - if (!(error = VOP_LEASE(dvp, td, td->td_ucred, LEASE_WRITE))) - error = VOP_WHITEOUT(dvp, &cn, CREATE); + error = VOP_WHITEOUT(dvp, &cn, CREATE); vn_finished_write(mp); @@ -949,9 +944,6 @@ unionfs_vn_create_on_upper(struct vnode **vpp, struct vnode *udvp, goto unionfs_vn_create_on_upper_free_out1; } - if ((error = VOP_LEASE(udvp, td, cred, LEASE_WRITE)) != 0) - goto unionfs_vn_create_on_upper_free_out1; - if ((error = VOP_CREATE(udvp, &vp, &cn, uvap)) != 0) goto unionfs_vn_create_on_upper_free_out1; @@ -999,10 +991,6 @@ unionfs_copyfile_core(struct vnode *lvp, struct vnode *uvp, uio.uio_segflg = UIO_SYSSPACE; uio.uio_offset = 0; - if ((error = VOP_LEASE(lvp, td, cred, LEASE_READ)) != 0) - return (error); - if ((error = VOP_LEASE(uvp, td, cred, LEASE_WRITE)) != 0) - return (error); buf = malloc(MAXBSIZE, M_TEMP, M_WAITOK); while (error == 0) { diff --git a/sys/fs/unionfs/union_vnops.c b/sys/fs/unionfs/union_vnops.c index d16851d883ea..8505cacc8f1a 100644 --- a/sys/fs/unionfs/union_vnops.c +++ b/sys/fs/unionfs/union_vnops.c @@ -902,27 +902,6 @@ unionfs_write(struct vop_write_args *ap) } static int -unionfs_lease(struct vop_lease_args *ap) -{ - int error; - struct unionfs_node *unp; - struct vnode *vp; - - UNIONFS_INTERNAL_DEBUG("unionfs_lease: enter\n"); - - KASSERT_UNIONFS_VNODE(ap->a_vp); - - unp = VTOUNIONFS(ap->a_vp); - vp = (unp->un_uppervp != NULLVP ? unp->un_uppervp : unp->un_lowervp); - - error = VOP_LEASE(vp, ap->a_td, ap->a_cred, ap->a_flag); - - UNIONFS_INTERNAL_DEBUG("unionfs_lease: lease (%d)\n", error); - - return (error); -} - -static int unionfs_ioctl(struct vop_ioctl_args *ap) { int error; @@ -947,7 +926,7 @@ unionfs_ioctl(struct vop_ioctl_args *ap) error = VOP_IOCTL(ovp, ap->a_command, ap->a_data, ap->a_fflag, ap->a_cred, ap->a_td); - UNIONFS_INTERNAL_DEBUG("unionfs_ioctl: lease (%d)\n", error); + UNIONFS_INTERNAL_DEBUG("unionfs_ioctl: leave (%d)\n", error); return (error); } @@ -2461,7 +2440,6 @@ struct vop_vector unionfs_vnodeops = { .vop_getwritemount = unionfs_getwritemount, .vop_inactive = unionfs_inactive, .vop_ioctl = unionfs_ioctl, - .vop_lease = unionfs_lease, .vop_link = unionfs_link, .vop_listextattr = unionfs_listextattr, .vop_lock1 = unionfs_lock, |
