btrfs: move fs_info::fs_frozen to the flags
We can keep the state among the other fs_info flags, there's no reason why fs_frozen would need to be separate. Reviewed-by: Nikolay Borisov <nborisov@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
@@ -2242,7 +2242,7 @@ static int btrfs_freeze(struct super_block *sb)
|
||||
struct btrfs_fs_info *fs_info = btrfs_sb(sb);
|
||||
struct btrfs_root *root = fs_info->tree_root;
|
||||
|
||||
fs_info->fs_frozen = 1;
|
||||
set_bit(BTRFS_FS_FROZEN, &fs_info->flags);
|
||||
/*
|
||||
* We don't need a barrier here, we'll wait for any transaction that
|
||||
* could be in progress on other threads (and do delayed iputs that
|
||||
@@ -2261,7 +2261,9 @@ static int btrfs_freeze(struct super_block *sb)
|
||||
|
||||
static int btrfs_unfreeze(struct super_block *sb)
|
||||
{
|
||||
btrfs_sb(sb)->fs_frozen = 0;
|
||||
struct btrfs_fs_info *fs_info = btrfs_sb(sb);
|
||||
|
||||
clear_bit(BTRFS_FS_FROZEN, &fs_info->flags);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user