During the mount context btrfs_open_devices() calls invalidate_bdev() for all the devices. So drop the invalidate_bdev() in open_ctree() which is only for the btrfs_fs_devices::latest_bdev.
The call trace is as shown below. btrfs_mount_root() | |_btrfs_parse_early_options (-o device only) | |_btrfs_scan_one_device | |_btrfs_read_disk_super() | |_read_cache_page_gfp() | |_btrfs_scan_one_device(mount-arg-dev only) | |_btrfs_read_disk_super() | |_read_cache_page_gfp() | | |_btrfs_open_devices(fsid:all) | |_btrfs_open_one_device() | |_btrfs_get_bdev_and_sb() <--- invalidate_bdev(fsid:all) | |_btrfs_read_dev_super() | |_btrfs_read_dev_one_super() | |___bread() | |_btrfs_fill_super() |_btrfs_open_ctree() <-- invalidate_bdev(latest_bdev) <-- redundant |_btrfs_read_dev_super(latest_bdev only) |_btrfs_read_dev_one_super(latest_bdev only) |___bread(latest_bdev) Signed-off-by: Anand Jain <anand.j...@oracle.com> --- fs/btrfs/disk-io.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index 110465bec775..628c2b1d1349 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c @@ -2553,8 +2553,6 @@ int open_ctree(struct super_block *sb, __setup_root(tree_root, fs_info, BTRFS_ROOT_TREE_OBJECTID); - invalidate_bdev(fs_devices->latest_bdev); - /* * Read super block and check the signature bytes only */ -- 2.7.0 -- To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html