mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-14 04:09:18 -04:00
btrfs: switch del_all argument of replay_dir_deletes() from int to bool
The argument has boolean semantics, so change its type from int to bool, making it more clear. Reviewed-by: Boris Burkov <boris@bur.io> Signed-off-by: Filipe Manana <fdmanana@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
committed by
David Sterba
parent
5f8882c854
commit
7077d7b872
@@ -112,7 +112,7 @@ static noinline int replay_dir_deletes(struct btrfs_trans_handle *trans,
|
||||
struct btrfs_root *root,
|
||||
struct btrfs_root *log,
|
||||
struct btrfs_path *path,
|
||||
u64 dirid, int del_all);
|
||||
u64 dirid, bool del_all);
|
||||
static void wait_log_commit(struct btrfs_root *root, int transid);
|
||||
|
||||
/*
|
||||
@@ -1628,8 +1628,7 @@ static noinline int fixup_inode_link_count(struct btrfs_trans_handle *trans,
|
||||
|
||||
if (inode->vfs_inode.i_nlink == 0) {
|
||||
if (S_ISDIR(inode->vfs_inode.i_mode)) {
|
||||
ret = replay_dir_deletes(trans, root, NULL, path,
|
||||
ino, 1);
|
||||
ret = replay_dir_deletes(trans, root, NULL, path, ino, true);
|
||||
if (ret)
|
||||
goto out;
|
||||
}
|
||||
@@ -2281,7 +2280,7 @@ static noinline int replay_dir_deletes(struct btrfs_trans_handle *trans,
|
||||
struct btrfs_root *root,
|
||||
struct btrfs_root *log,
|
||||
struct btrfs_path *path,
|
||||
u64 dirid, int del_all)
|
||||
u64 dirid, bool del_all)
|
||||
{
|
||||
u64 range_start;
|
||||
u64 range_end;
|
||||
@@ -2443,8 +2442,8 @@ static int replay_one_buffer(struct btrfs_root *log, struct extent_buffer *eb,
|
||||
break;
|
||||
mode = btrfs_inode_mode(eb, inode_item);
|
||||
if (S_ISDIR(mode)) {
|
||||
ret = replay_dir_deletes(wc->trans,
|
||||
root, log, path, key.objectid, 0);
|
||||
ret = replay_dir_deletes(wc->trans, root, log, path,
|
||||
key.objectid, false);
|
||||
if (ret)
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user