Displaying 2 results from an estimated 2 matches for "btrfs_super_flags".
2010 Dec 01
2
[RFC PATCH 4/4 v2] Btrfs: deal with filesystem state at mount, umount
...int read_only);
/*
* end_io_wq structs are used to do processing in task context when an IO is
@@ -1700,6 +1702,11 @@ struct btrfs_root *open_ctree(struct super_block *sb,
if (!btrfs_super_root(disk_super))
goto fail_iput;
+ /* check filesystem state */
+ fs_info->fs_state |= btrfs_super_flags(disk_super);
+
+ btrfs_check_super_valid(fs_info, sb->s_flags & MS_RDONLY);
+
ret = btrfs_parse_options(tree_root, options);
if (ret) {
err = ret;
@@ -2405,10 +2412,17 @@ int btrfs_commit_super(struct btrfs_root *root)
up_write(&root->fs_info->cleanup_work_sem);
trans...
2009 Nov 14
2
[PATCH] btrfs-progs: Check mount status of multidevice filesystems
...e
- ret = btrfs_open_devices(fs_devices, O_RDONLY);
+ ret = btrfs_open_devices(fs_devices, O_RDONLY, check_mount);
BUG_ON(ret);
fs_info->super_bytenr = sb_bytenr;
@@ -725,7 +725,7 @@ struct btrfs_root *open_ctree_fd(int fp, const char *path, u64 sb_bytenr,
BTRFS_UUID_SIZE);
if (!(btrfs_super_flags(disk_super) & BTRFS_SUPER_FLAG_METADUMP)) {
- ret = btrfs_read_chunk_tree(chunk_root);
+ ret = btrfs_read_chunk_tree(chunk_root, check_mount);
BUG_ON(ret);
}
diff --git a/disk-io.h b/disk-io.h
index 49e5692..1d6519e 100644
--- a/disk-io.h
+++ b/disk-io.h
@@ -43,9 +43,9 @@ struct extent...