summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/tree-log.c
diff options
context:
space:
mode:
authorNikolay Borisov <n.borisov.lkml@gmail.com>2017-01-17 17:31:35 -0500
committerDavid Sterba <dsterba@suse.com>2017-02-14 09:50:55 -0500
commit4791c8f19c45d1a4e7fb5e9a6da532f7cd1fca99 (patch)
treee08d3398277ccfaf5e0ef16258d96b157fefbc60 /fs/btrfs/tree-log.c
parent481b01c0d3cbbca7a97f140286738a3e02ac9d4c (diff)
btrfs: Make btrfs_check_ref_name_override take btrfs_inode
Signed-off-by: Nikolay Borisov <n.borisov.lkml@gmail.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/tree-log.c')
-rw-r--r--fs/btrfs/tree-log.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c
index 20718cfebf89..7669e95be423 100644
--- a/fs/btrfs/tree-log.c
+++ b/fs/btrfs/tree-log.c
@@ -4495,7 +4495,7 @@ static int btrfs_log_trailing_hole(struct btrfs_trans_handle *trans,
4495static int btrfs_check_ref_name_override(struct extent_buffer *eb, 4495static int btrfs_check_ref_name_override(struct extent_buffer *eb,
4496 const int slot, 4496 const int slot,
4497 const struct btrfs_key *key, 4497 const struct btrfs_key *key,
4498 struct inode *inode, 4498 struct btrfs_inode *inode,
4499 u64 *other_ino) 4499 u64 *other_ino)
4500{ 4500{
4501 int ret; 4501 int ret;
@@ -4551,9 +4551,8 @@ static int btrfs_check_ref_name_override(struct extent_buffer *eb,
4551 } 4551 }
4552 4552
4553 read_extent_buffer(eb, name, name_ptr, this_name_len); 4553 read_extent_buffer(eb, name, name_ptr, this_name_len);
4554 di = btrfs_lookup_dir_item(NULL, BTRFS_I(inode)->root, 4554 di = btrfs_lookup_dir_item(NULL, inode->root, search_path,
4555 search_path, parent, 4555 parent, name, this_name_len, 0);
4556 name, this_name_len, 0);
4557 if (di && !IS_ERR(di)) { 4556 if (di && !IS_ERR(di)) {
4558 struct btrfs_key di_key; 4557 struct btrfs_key di_key;
4559 4558
@@ -4769,7 +4768,7 @@ again:
4769 4768
4770 ret = btrfs_check_ref_name_override(path->nodes[0], 4769 ret = btrfs_check_ref_name_override(path->nodes[0],
4771 path->slots[0], 4770 path->slots[0],
4772 &min_key, inode, 4771 &min_key, BTRFS_I(inode),
4773 &other_ino); 4772 &other_ino);
4774 if (ret < 0) { 4773 if (ret < 0) {
4775 err = ret; 4774 err = ret;