summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnand Jain <anand.jain@oracle.com>2019-04-12 04:02:55 -0400
committerDavid Sterba <dsterba@suse.com>2019-04-29 13:02:44 -0400
commit2d74fa3efcffe456d16833af118ffe0cb0ee6785 (patch)
tree74aaa183ef400b8dd5da6d3f081352890eddd6c6
parentcac237ae095f6d92bda05ccd6df349d20f1a4bfc (diff)
btrfs: rename do_setxattr to btrfs_setxattr
When trans is not NULL btrfs_setxattr() calls do_setxattr() directly with a check for readonly root. Rename do_setxattr() btrfs_setxattr() in preparation to call do_setxattr() directly instead. Preparatory patch, no functional changes. Signed-off-by: Anand Jain <anand.jain@oracle.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
-rw-r--r--fs/btrfs/xattr.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/btrfs/xattr.c b/fs/btrfs/xattr.c
index 38eb78aac0a7..fd1469ef55d6 100644
--- a/fs/btrfs/xattr.c
+++ b/fs/btrfs/xattr.c
@@ -76,9 +76,9 @@ out:
76 return ret; 76 return ret;
77} 77}
78 78
79static int do_setxattr(struct btrfs_trans_handle *trans, 79static int btrfs_setxattr(struct btrfs_trans_handle *trans,
80 struct inode *inode, const char *name, 80 struct inode *inode, const char *name,
81 const void *value, size_t size, int flags) 81 const void *value, size_t size, int flags)
82{ 82{
83 struct btrfs_dir_item *di = NULL; 83 struct btrfs_dir_item *di = NULL;
84 struct btrfs_root *root = BTRFS_I(inode)->root; 84 struct btrfs_root *root = BTRFS_I(inode)->root;
@@ -231,13 +231,13 @@ int btrfs_setxattr_trans(struct btrfs_trans_handle *trans,
231 return -EROFS; 231 return -EROFS;
232 232
233 if (trans) 233 if (trans)
234 return do_setxattr(trans, inode, name, value, size, flags); 234 return btrfs_setxattr(trans, inode, name, value, size, flags);
235 235
236 trans = btrfs_start_transaction(root, 2); 236 trans = btrfs_start_transaction(root, 2);
237 if (IS_ERR(trans)) 237 if (IS_ERR(trans))
238 return PTR_ERR(trans); 238 return PTR_ERR(trans);
239 239
240 ret = do_setxattr(trans, inode, name, value, size, flags); 240 ret = btrfs_setxattr(trans, inode, name, value, size, flags);
241 if (ret) 241 if (ret)
242 goto out; 242 goto out;
243 243