提交 da5aa861 编写于 作者: R Rafael J. Wysocki 提交者: Al Viro

fix block device fallout from ->fsync() changes

blkdev_fsync() needs to write pages in pagecache...
Signed-off-by: NRafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
上级 cfe22345
......@@ -387,6 +387,10 @@ int blkdev_fsync(struct file *filp, loff_t start, loff_t end, int datasync)
struct inode *bd_inode = filp->f_mapping->host;
struct block_device *bdev = I_BDEV(bd_inode);
int error;
error = filemap_write_and_wait_range(filp->f_mapping, start, end);
if (error)
return error;
/*
* There is no need to serialise calls to blkdev_issue_flush with
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册