diff options
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r-- | fs/btrfs/inode.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 4deb280f8969..c41db6d45ab6 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c | |||
@@ -3968,7 +3968,7 @@ err: | |||
3968 | return ret; | 3968 | return ret; |
3969 | } | 3969 | } |
3970 | 3970 | ||
3971 | int btrfs_write_inode(struct inode *inode, int wait) | 3971 | int btrfs_write_inode(struct inode *inode, struct writeback_control *wbc) |
3972 | { | 3972 | { |
3973 | struct btrfs_root *root = BTRFS_I(inode)->root; | 3973 | struct btrfs_root *root = BTRFS_I(inode)->root; |
3974 | struct btrfs_trans_handle *trans; | 3974 | struct btrfs_trans_handle *trans; |
@@ -3977,7 +3977,7 @@ int btrfs_write_inode(struct inode *inode, int wait) | |||
3977 | if (root->fs_info->btree_inode == inode) | 3977 | if (root->fs_info->btree_inode == inode) |
3978 | return 0; | 3978 | return 0; |
3979 | 3979 | ||
3980 | if (wait) { | 3980 | if (wbc->sync_mode == WB_SYNC_ALL) { |
3981 | trans = btrfs_join_transaction(root, 1); | 3981 | trans = btrfs_join_transaction(root, 1); |
3982 | btrfs_set_trans_block_group(trans, inode); | 3982 | btrfs_set_trans_block_group(trans, inode); |
3983 | ret = btrfs_commit_transaction(trans, root); | 3983 | ret = btrfs_commit_transaction(trans, root); |