summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/defrag.h
diff options
context:
space:
mode:
authorFilipe Manana <fdmanana@suse.com>2023-09-22 12:37:56 +0200
committerDavid Sterba <dsterba@suse.com>2023-10-12 16:44:13 +0200
commit1723270f0c29cc27dbe9e554a3f35abd2e4eb945 (patch)
tree402d7d5ecc50003721ed7edd395299aacf656605 /fs/btrfs/defrag.h
parentbtrfs: remove redundant root argument from fixup_inode_link_count() (diff)
downloadlinux-1723270f0c29cc27dbe9e554a3f35abd2e4eb945.tar.xz
linux-1723270f0c29cc27dbe9e554a3f35abd2e4eb945.zip
btrfs: move btrfs_defrag_root() to defrag.{c,h}
The btrfs_defrag_root() function does not really belong in the transaction.{c,h} module and as we have a defrag.{c,h} nowadays, move it to there instead. This also allows to stop exporting btrfs_defrag_leaves(), so we can make it static. Reviewed-by: Qu Wenruo <wqu@suse.com> Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> [ rename info to fs_info for consistency ] Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/defrag.h')
-rw-r--r--fs/btrfs/defrag.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/defrag.h b/fs/btrfs/defrag.h
index 5305f2283b5e..5a62763528d1 100644
--- a/fs/btrfs/defrag.h
+++ b/fs/btrfs/defrag.h
@@ -12,7 +12,7 @@ int btrfs_add_inode_defrag(struct btrfs_trans_handle *trans,
struct btrfs_inode *inode, u32 extent_thresh);
int btrfs_run_defrag_inodes(struct btrfs_fs_info *fs_info);
void btrfs_cleanup_defrag_inodes(struct btrfs_fs_info *fs_info);
-int btrfs_defrag_leaves(struct btrfs_trans_handle *trans, struct btrfs_root *root);
+int btrfs_defrag_root(struct btrfs_root *root);
static inline int btrfs_defrag_cancelled(struct btrfs_fs_info *fs_info)
{