diff options
author | Nikolay Borisov <n.borisov.lkml@gmail.com> | 2017-01-17 17:31:38 -0500 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2017-02-14 09:50:55 -0500 |
commit | a0308dd7e01dad075fa8f2c96c905e5841d920fa (patch) | |
tree | 613b2adcf32bc7eb82e6b59fd45032fe2d796c55 /fs/btrfs/tree-log.c | |
parent | 1a93c36acdef62ef1f5dccf058328d4d5d6c0e70 (diff) |
btrfs: Make btrfs_log_trailing_hole 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.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c index 1301c517c2f0..9f2c42016825 100644 --- a/fs/btrfs/tree-log.c +++ b/fs/btrfs/tree-log.c | |||
@@ -4372,7 +4372,7 @@ static int btrfs_log_all_xattrs(struct btrfs_trans_handle *trans, | |||
4372 | */ | 4372 | */ |
4373 | static int btrfs_log_trailing_hole(struct btrfs_trans_handle *trans, | 4373 | static int btrfs_log_trailing_hole(struct btrfs_trans_handle *trans, |
4374 | struct btrfs_root *root, | 4374 | struct btrfs_root *root, |
4375 | struct inode *inode, | 4375 | struct btrfs_inode *inode, |
4376 | struct btrfs_path *path) | 4376 | struct btrfs_path *path) |
4377 | { | 4377 | { |
4378 | struct btrfs_fs_info *fs_info = root->fs_info; | 4378 | struct btrfs_fs_info *fs_info = root->fs_info; |
@@ -4382,8 +4382,8 @@ static int btrfs_log_trailing_hole(struct btrfs_trans_handle *trans, | |||
4382 | u64 hole_size; | 4382 | u64 hole_size; |
4383 | struct extent_buffer *leaf; | 4383 | struct extent_buffer *leaf; |
4384 | struct btrfs_root *log = root->log_root; | 4384 | struct btrfs_root *log = root->log_root; |
4385 | const u64 ino = btrfs_ino(BTRFS_I(inode)); | 4385 | const u64 ino = btrfs_ino(inode); |
4386 | const u64 i_size = i_size_read(inode); | 4386 | const u64 i_size = i_size_read(&inode->vfs_inode); |
4387 | 4387 | ||
4388 | if (!btrfs_fs_incompat(fs_info, NO_HOLES)) | 4388 | if (!btrfs_fs_incompat(fs_info, NO_HOLES)) |
4389 | return 0; | 4389 | return 0; |
@@ -4925,7 +4925,7 @@ next_key: | |||
4925 | if (max_key.type >= BTRFS_EXTENT_DATA_KEY && !fast_search) { | 4925 | if (max_key.type >= BTRFS_EXTENT_DATA_KEY && !fast_search) { |
4926 | btrfs_release_path(path); | 4926 | btrfs_release_path(path); |
4927 | btrfs_release_path(dst_path); | 4927 | btrfs_release_path(dst_path); |
4928 | err = btrfs_log_trailing_hole(trans, root, inode, path); | 4928 | err = btrfs_log_trailing_hole(trans, root, BTRFS_I(inode), path); |
4929 | if (err) | 4929 | if (err) |
4930 | goto out_unlock; | 4930 | goto out_unlock; |
4931 | } | 4931 | } |