summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authorrwatson <rwatson@FreeBSD.org>2005-02-08 17:05:38 +0000
committerrwatson <rwatson@FreeBSD.org>2005-02-08 17:05:38 +0000
commit81617011cd4fc0a322fee7174006255fc9f5e82c (patch)
tree4e3eefdf7d00189a432c579dd3a8fa2e0674493b /sys
parentcb73ebe1308aef26a78f6ffd091d66356e9d0c87 (diff)
downloadFreeBSD-src-81617011cd4fc0a322fee7174006255fc9f5e82c.zip
FreeBSD-src-81617011cd4fc0a322fee7174006255fc9f5e82c.tar.gz
Don't use VOP_LEASE() with operations on extended attribute backing
files. Pointed out by: phk
Diffstat (limited to 'sys')
-rw-r--r--sys/ufs/ufs/ufs_extattr.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/sys/ufs/ufs/ufs_extattr.c b/sys/ufs/ufs/ufs_extattr.c
index 3d14e01..2d72a80 100644
--- a/sys/ufs/ufs/ufs_extattr.c
+++ b/sys/ufs/ufs/ufs_extattr.c
@@ -616,7 +616,6 @@ ufs_extattr_enable(struct ufsmount *ump, int attrnamespace,
auio.uio_rw = UIO_READ;
auio.uio_td = td;
- VOP_LEASE(backing_vnode, td, td->td_ucred, LEASE_WRITE);
vn_lock(backing_vnode, LK_SHARED | LK_NOPAUSE | LK_RETRY, td);
error = VOP_READ(backing_vnode, &auio, IO_NODELOCKED,
ump->um_extattr.uepm_ucred);
@@ -874,9 +873,7 @@ ufs_extattr_get(struct vnode *vp, int attrnamespace, const char *name,
/*
* Acquire locks.
- */
- VOP_LEASE(attribute->uele_backing_vnode, td, cred, LEASE_READ);
- /*
+ *
* Don't need to get a lock on the backing file if the getattr is
* being applied to the backing file, as the lock is already held.
*/
@@ -1086,10 +1083,7 @@ ufs_extattr_set(struct vnode *vp, int attrnamespace, const char *name,
/*
* Acquire locks.
- */
- VOP_LEASE(attribute->uele_backing_vnode, td, cred, LEASE_WRITE);
-
- /*
+ *
* Don't need to get a lock on the backing file if the setattr is
* being applied to the backing file, as the lock is already held.
*/
@@ -1186,8 +1180,6 @@ ufs_extattr_rm(struct vnode *vp, int attrnamespace, const char *name,
local_aio.uio_offset = base_offset;
local_aio.uio_resid = sizeof(struct ufs_extattr_header);
- VOP_LEASE(attribute->uele_backing_vnode, td, cred, LEASE_WRITE);
-
/*
* Don't need to get the lock on the backing vnode if the vnode we're
* modifying is it, as we already hold the lock.
OpenPOWER on IntegriCloud