diff options
author | Christoph Hellwig <hch@lst.de> | 2006-02-01 03:06:45 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-02-01 08:53:25 -0800 |
commit | c87d0c07ea198db1ce451421904edd60b7d385ee (patch) | |
tree | c6c58f49d3c9bf8fab0c27cf8335028f17614470 /fs/reiserfs | |
parent | e5dd259f78ba0fd0c7bfc5c52179dbbff3eb48aa (diff) | |
download | linux-c87d0c07ea198db1ce451421904edd60b7d385ee.tar.bz2 |
[PATCH] reiserfs: remove reiserfs_permission_locked
This function is completely unused since the xattr permission checking
changes. Remove it and fold __reiserfs_permission into
reiserfs_permission.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Cc: Jeff Mahoney <jeffm@suse.com>
Cc: Chris Mason <mason@suse.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/reiserfs')
-rw-r--r-- | fs/reiserfs/xattr.c | 30 |
1 files changed, 8 insertions, 22 deletions
diff --git a/fs/reiserfs/xattr.c b/fs/reiserfs/xattr.c index 4f0db4e54517..2f085845f670 100644 --- a/fs/reiserfs/xattr.c +++ b/fs/reiserfs/xattr.c @@ -1319,9 +1319,7 @@ int reiserfs_xattr_init(struct super_block *s, int mount_flags) return err; } -static int -__reiserfs_permission(struct inode *inode, int mask, struct nameidata *nd, - int need_lock) +int reiserfs_permission(struct inode *inode, int mask, struct nameidata *nd) { umode_t mode = inode->i_mode; @@ -1357,15 +1355,14 @@ __reiserfs_permission(struct inode *inode, int mask, struct nameidata *nd, if (!(mode & S_IRWXG)) goto check_groups; - if (need_lock) { - reiserfs_read_lock_xattr_i(inode); - reiserfs_read_lock_xattrs(inode->i_sb); - } + reiserfs_read_lock_xattr_i(inode); + reiserfs_read_lock_xattrs(inode->i_sb); + acl = reiserfs_get_acl(inode, ACL_TYPE_ACCESS); - if (need_lock) { - reiserfs_read_unlock_xattrs(inode->i_sb); - reiserfs_read_unlock_xattr_i(inode); - } + + reiserfs_read_unlock_xattrs(inode->i_sb); + reiserfs_read_unlock_xattr_i(inode); + if (IS_ERR(acl)) { if (PTR_ERR(acl) == -ENODATA) goto check_groups; @@ -1414,14 +1411,3 @@ __reiserfs_permission(struct inode *inode, int mask, struct nameidata *nd, return -EACCES; } - -int reiserfs_permission(struct inode *inode, int mask, struct nameidata *nd) -{ - return __reiserfs_permission(inode, mask, nd, 1); -} - -int -reiserfs_permission_locked(struct inode *inode, int mask, struct nameidata *nd) -{ - return __reiserfs_permission(inode, mask, nd, 0); -} |