Btrfs: remove no longer used logged range variables when logging extents
The logged_start and logged_end variables, at btrfs_log_changed_extents, were added in commit8c6c592831
("btrfs: log csums for all modified extents"). However since the recent simplification for fsync, which makes us wait for all ordered extents to complete before logging extents, we no longer need those variables. Commita2120a473a
("btrfs: clean up the left over logged_list usage") forgot to remove them. Reviewed-by: Nikolay Borisov <nborisov@suse.com> Signed-off-by: Filipe Manana <fdmanana@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
7566ec393f
commit
ce02f03266
|
@ -4383,7 +4383,6 @@ static int btrfs_log_changed_extents(struct btrfs_trans_handle *trans,
|
||||||
struct extent_map *em, *n;
|
struct extent_map *em, *n;
|
||||||
struct list_head extents;
|
struct list_head extents;
|
||||||
struct extent_map_tree *tree = &inode->extent_tree;
|
struct extent_map_tree *tree = &inode->extent_tree;
|
||||||
u64 logged_start, logged_end;
|
|
||||||
u64 test_gen;
|
u64 test_gen;
|
||||||
int ret = 0;
|
int ret = 0;
|
||||||
int num = 0;
|
int num = 0;
|
||||||
|
@ -4392,8 +4391,6 @@ static int btrfs_log_changed_extents(struct btrfs_trans_handle *trans,
|
||||||
|
|
||||||
write_lock(&tree->lock);
|
write_lock(&tree->lock);
|
||||||
test_gen = root->fs_info->last_trans_committed;
|
test_gen = root->fs_info->last_trans_committed;
|
||||||
logged_start = start;
|
|
||||||
logged_end = end;
|
|
||||||
|
|
||||||
list_for_each_entry_safe(em, n, &tree->modified_extents, list) {
|
list_for_each_entry_safe(em, n, &tree->modified_extents, list) {
|
||||||
/*
|
/*
|
||||||
|
@ -4434,11 +4431,6 @@ static int btrfs_log_changed_extents(struct btrfs_trans_handle *trans,
|
||||||
em->start >= i_size_read(&inode->vfs_inode))
|
em->start >= i_size_read(&inode->vfs_inode))
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
if (em->start < logged_start)
|
|
||||||
logged_start = em->start;
|
|
||||||
if ((em->start + em->len - 1) > logged_end)
|
|
||||||
logged_end = em->start + em->len - 1;
|
|
||||||
|
|
||||||
/* Need a ref to keep it from getting evicted from cache */
|
/* Need a ref to keep it from getting evicted from cache */
|
||||||
refcount_inc(&em->refs);
|
refcount_inc(&em->refs);
|
||||||
set_bit(EXTENT_FLAG_LOGGING, &em->flags);
|
set_bit(EXTENT_FLAG_LOGGING, &em->flags);
|
||||||
|
|
Loading…
Reference in New Issue