btrfs: Replace clear_extent_bit with unlock_extent
authorNikolay Borisov <nborisov@suse.com>
Tue, 12 Mar 2019 15:20:28 +0000 (17:20 +0200)
committerDavid Sterba <dsterba@suse.com>
Thu, 2 May 2019 11:48:19 +0000 (13:48 +0200)
Reviewed-by: Johannes Thumshirn <jthumshirn@suse.de>
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/inode.c

index f83c8edd1703fec079aa4f7402c70a0bcd227639..05362559645e1c508bd0d6e22802ec5928de7d85 100644 (file)
@@ -1196,8 +1196,7 @@ static int cow_file_range_async(struct inode *inode, struct page *locked_page,
        int i;
        bool should_compress;
 
-       clear_extent_bit(&BTRFS_I(inode)->io_tree, start, end, EXTENT_LOCKED,
-                        1, 0, NULL);
+       unlock_extent(&BTRFS_I(inode)->io_tree, start, end);
 
        if (BTRFS_I(inode)->flags & BTRFS_INODE_NOCOMPRESS &&
            !btrfs_test_opt(fs_info, FORCE_COMPRESS)) {