Skip to content

Commit

Permalink
Btrfs: drop useless LIST_HEAD in merge_reloc_root
Browse files Browse the repository at this point in the history
Drop LIST_HEAD where the variable it declares is never used.

The uses were removed in 3fd0a55 ("Btrfs: Metadata ENOSPC
handling for balance"), but not the declaration.

The semantic patch that fixes this problem is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
identifier x;
@@
- LIST_HEAD(x);
  ... when != x
// </smpl>

Signed-off-by: Julia Lawall <Julia.Lawall@lip6.fr>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
  • Loading branch information
Julia Lawall authored and David Sterba committed Feb 25, 2019
1 parent 5908e6b commit 9cf10cc
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion fs/btrfs/relocation.c
Original file line number Diff line number Diff line change
Expand Up @@ -2128,7 +2128,6 @@ static noinline_for_stack int merge_reloc_root(struct reloc_control *rc,
struct btrfs_root *root)
{
struct btrfs_fs_info *fs_info = rc->extent_root->fs_info;
LIST_HEAD(inode_list);
struct btrfs_key key;
struct btrfs_key next_key;
struct btrfs_trans_handle *trans = NULL;
Expand Down

0 comments on commit 9cf10cc

Please sign in to comment.