Skip to content

Remove duplicate code in btrfs_prune_dentries/find_next_inode

Nikolay Borisov linux-btrfs 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 7 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3btrfs: introduce btrfs_find_inodefs/btrfs/ctree.h fs/btrfs/inode.c+45 -04 replies
2/3btrfs: use btrfs_find_inode in btrfs_prune_dentriesfs/btrfs/inode.c+17 -302 replies
3/3btrfs: use btrfs_find_inode in find_next_inodefs/btrfs/relocation.c+19 -350 replies

Reviews trailers per patch

None of the 3 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchSweet Tea Dorminy
SeriesR-b
1/3
2/3
3/3

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/3] Remove duplicate code in btrfs_prune_dentries/find_next_inode

Both functions share similar logic to find a particular inode. So this series first factors out the common code in btrfs_find_inode and subsequently uses it to remove most of the internals of the two client functions. This greatly streamlines the codeflow in the affected functions.

The changes survived a full xfstest run.

Nikolay Borisov (3):
btrfs: introduce btrfs_find_inode
btrfs: use btrfs_find_inode in btrfs_prune_dentries
btrfs: use btrfs_find_inode in find_next_inode

 fs/btrfs/ctree.h      |  1 +
 fs/btrfs/inode.c      | 75 ++++++++++++++++++++++++++++++-------------
 fs/btrfs/relocation.c | 54 +++++++++++--------------------
 3 files changed, 73 insertions(+), 57 deletions(-)

--
2.25.1