diff options
author | Josef Bacik <josef@toxicpanda.com> | 2022-09-12 12:27:46 -0700 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2022-09-29 17:08:28 +0200 |
commit | 80f9d24130e45b01984a918d6b2006c10687b138 (patch) | |
tree | ecb419e7c7ce6628460f48b42933479988646677 /fs/btrfs/inode.c | |
parent | d2c7a19f5c82ace6ea0ec00ae53c6dd97ee8e274 (diff) | |
download | linux-80f9d24130e45b01984a918d6b2006c10687b138.tar.gz |
btrfs: make btrfs_check_nocow_lock nowait compatible
Now all the helpers that btrfs_check_nocow_lock uses handle nowait, add
a nowait flag to btrfs_check_nocow_lock so it can be used by the write
path.
Reviewed-by: Filipe Manana <fdmanana@suse.com>
Signed-off-by: Josef Bacik <josef@toxicpanda.com>
Signed-off-by: Stefan Roesch <shr@fb.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r-- | fs/btrfs/inode.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 0c92b22aa3b6..d5fac2979deb 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -4887,7 +4887,7 @@ int btrfs_truncate_block(struct btrfs_inode *inode, loff_t from, loff_t len, ret = btrfs_check_data_free_space(inode, &data_reserved, block_start, blocksize, false); if (ret < 0) { - if (btrfs_check_nocow_lock(inode, block_start, &write_bytes) > 0) { + if (btrfs_check_nocow_lock(inode, block_start, &write_bytes, false) > 0) { /* For nocow case, no need to reserve data space */ only_release_metadata = true; } else { |