Btrfs: Fix compressed checksum fsync log copies
The fsync logging code makes sure to onl copy the relevant checksum for each extent based on the file extent pointers it finds. But for compressed extents, it needs to copy the checksum for the entire extent. Signed-off-by: Chris Mason <chris.mason@oracle.com>
This commit is contained in:
@@ -1228,7 +1228,8 @@ int btrfs_sync_file(struct file *file, struct dentry *dentry, int datasync)
|
||||
mutex_unlock(&root->fs_info->trans_mutex);
|
||||
|
||||
root->fs_info->tree_log_batch++;
|
||||
filemap_fdatawait(inode->i_mapping);
|
||||
filemap_fdatawrite(inode->i_mapping);
|
||||
btrfs_wait_ordered_range(inode, 0, (u64)-1);
|
||||
root->fs_info->tree_log_batch++;
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user