Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

xen-blkback: use sync_blockdev

Use sync_blockdev instead of opencoding it.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com>
Link: https://lore.kernel.org/r/20211019062530.2174626-4-hch@lst.de
Signed-off-by: Jens Axboe <axboe@kernel.dk>

authored by

Christoph Hellwig and committed by
Jens Axboe
d39b0a2f 70164eb6

+1 -1
+1 -1
drivers/block/xen-blkback/xenbus.c
··· 98 98 return; 99 99 } 100 100 101 - err = filemap_write_and_wait(blkif->vbd.bdev->bd_inode->i_mapping); 101 + err = sync_blockdev(blkif->vbd.bdev); 102 102 if (err) { 103 103 xenbus_dev_error(blkif->be->dev, err, "block flush"); 104 104 return;