diff options
author | Edmund Nadolski <enadolski@suse.com> | 2017-11-20 15:24:47 -0500 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2018-01-22 10:08:14 -0500 |
commit | 41a1eadad719168ce5f6cfcfda6ea45134f2424a (patch) | |
tree | 456591e56b448bd4f72c2cc24f6e2157fb2075f7 /fs/btrfs/tree-log.c | |
parent | 71a635516ca521931be418827150f782b0a03ae7 (diff) |
btrfs: btrfs_inode_log_parent should use defined inode_only values.
Replace hardcoded numeric argument values for inode_only with the
constants defined for that use.
Signed-off-by: Edmund Nadolski <enadolski@suse.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/tree-log.c')
-rw-r--r-- | fs/btrfs/tree-log.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c index a806182dfea6..ee1aaed1330e 100644 --- a/fs/btrfs/tree-log.c +++ b/fs/btrfs/tree-log.c | |||
@@ -5403,11 +5403,10 @@ static int btrfs_log_inode_parent(struct btrfs_trans_handle *trans, | |||
5403 | struct dentry *parent, | 5403 | struct dentry *parent, |
5404 | const loff_t start, | 5404 | const loff_t start, |
5405 | const loff_t end, | 5405 | const loff_t end, |
5406 | int exists_only, | 5406 | int inode_only, |
5407 | struct btrfs_log_ctx *ctx) | 5407 | struct btrfs_log_ctx *ctx) |
5408 | { | 5408 | { |
5409 | struct btrfs_fs_info *fs_info = root->fs_info; | 5409 | struct btrfs_fs_info *fs_info = root->fs_info; |
5410 | int inode_only = exists_only ? LOG_INODE_EXISTS : LOG_INODE_ALL; | ||
5411 | struct super_block *sb; | 5410 | struct super_block *sb; |
5412 | struct dentry *old_parent = NULL; | 5411 | struct dentry *old_parent = NULL; |
5413 | int ret = 0; | 5412 | int ret = 0; |
@@ -5573,7 +5572,7 @@ int btrfs_log_dentry_safe(struct btrfs_trans_handle *trans, | |||
5573 | int ret; | 5572 | int ret; |
5574 | 5573 | ||
5575 | ret = btrfs_log_inode_parent(trans, root, BTRFS_I(d_inode(dentry)), | 5574 | ret = btrfs_log_inode_parent(trans, root, BTRFS_I(d_inode(dentry)), |
5576 | parent, start, end, 0, ctx); | 5575 | parent, start, end, LOG_INODE_ALL, ctx); |
5577 | dput(parent); | 5576 | dput(parent); |
5578 | 5577 | ||
5579 | return ret; | 5578 | return ret; |
@@ -5836,6 +5835,6 @@ int btrfs_log_new_name(struct btrfs_trans_handle *trans, | |||
5836 | return 0; | 5835 | return 0; |
5837 | 5836 | ||
5838 | return btrfs_log_inode_parent(trans, root, inode, parent, 0, | 5837 | return btrfs_log_inode_parent(trans, root, inode, parent, 0, |
5839 | LLONG_MAX, 1, NULL); | 5838 | LLONG_MAX, LOG_INODE_EXISTS, NULL); |
5840 | } | 5839 | } |
5841 | 5840 | ||