From: Nikolay Borisov Date: Tue, 14 May 2019 10:54:38 +0000 (+0300) Subject: btrfs: Don't opencode sync_blockdev in btrfs_init_dev_replace_tgtdev X-Git-Tag: v5.4-rc1~213^2~112 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ddb93784692fd41d7f1e74cf8b441428b7e57a64;p=platform%2Fkernel%2Flinux-rpi.git btrfs: Don't opencode sync_blockdev in btrfs_init_dev_replace_tgtdev Using sync_blockdev makes it plain obvious what's happening. No functional changes. Reviewed-by: Johannes Thumshirn Signed-off-by: Nikolay Borisov Reviewed-by: David Sterba Signed-off-by: David Sterba --- diff --git a/fs/btrfs/dev-replace.c b/fs/btrfs/dev-replace.c index ee0989c..1b83787 100644 --- a/fs/btrfs/dev-replace.c +++ b/fs/btrfs/dev-replace.c @@ -201,7 +201,7 @@ static int btrfs_init_dev_replace_tgtdev(struct btrfs_fs_info *fs_info, return PTR_ERR(bdev); } - filemap_write_and_wait(bdev->bd_inode->i_mapping); + sync_blockdev(bdev); devices = &fs_info->fs_devices->devices; list_for_each_entry(device, devices, dev_list) {