]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - fs/block_dev.c
Merge branch 'usb-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh...
[mirror_ubuntu-bionic-kernel.git] / fs / block_dev.c
index f286805532882ab33d5431682b64ce5e1f71ec6f..ff77262e887cb66819f31d781e679eccb2d1975a 100644 (file)
@@ -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