summaryrefslogtreecommitdiff
path: root/fs/btrfs/ctree.c
diff options
context:
space:
mode:
authorNikolay Borisov <nborisov@suse.com>2020-11-12 14:24:02 +0300
committerDavid Sterba <dsterba@suse.com>2020-12-08 17:54:12 +0300
commitd5286a92ea76a124d6cfa1e261394da858125d99 (patch)
treee66789ddf53d62f6b384f022ed9775558290493b /fs/btrfs/ctree.c
parentf30bed83426c5cb9fce6cabb3f7cc5a9d5428fcc (diff)
downloadlinux-d5286a92ea76a124d6cfa1e261394da858125d99.tar.xz
btrfs: remove useless return value statement in split_node
At the point when we set 'ret = 0' it's guaranteed that the function is going to return 0 so directly return 0. No functional changes. Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Signed-off-by: Nikolay Borisov <nborisov@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/ctree.c')
-rw-r--r--fs/btrfs/ctree.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c
index 778a6d580545..60135f6e6441 100644
--- a/fs/btrfs/ctree.c
+++ b/fs/btrfs/ctree.c
@@ -3459,7 +3459,6 @@ static noinline int split_node(struct btrfs_trans_handle *trans,
(c_nritems - mid) * sizeof(struct btrfs_key_ptr));
btrfs_set_header_nritems(split, c_nritems - mid);
btrfs_set_header_nritems(c, mid);
- ret = 0;
btrfs_mark_buffer_dirty(c);
btrfs_mark_buffer_dirty(split);
@@ -3477,7 +3476,7 @@ static noinline int split_node(struct btrfs_trans_handle *trans,
btrfs_tree_unlock(split);
free_extent_buffer(split);
}
- return ret;
+ return 0;
}
/*