|
@@ -1167,7 +1167,6 @@ static int cow_file_range_async(struct inode *inode, struct page *locked_page,
|
|
|
struct btrfs_root *root = BTRFS_I(inode)->root;
|
|
|
unsigned long nr_pages;
|
|
|
u64 cur_end;
|
|
|
- int limit = 10 * SZ_1M;
|
|
|
|
|
|
clear_extent_bit(&BTRFS_I(inode)->io_tree, start, end, EXTENT_LOCKED,
|
|
|
1, 0, NULL, GFP_NOFS);
|
|
@@ -1199,12 +1198,6 @@ static int cow_file_range_async(struct inode *inode, struct page *locked_page,
|
|
|
|
|
|
btrfs_queue_work(fs_info->delalloc_workers, &async_cow->work);
|
|
|
|
|
|
- if (atomic_read(&fs_info->async_delalloc_pages) > limit) {
|
|
|
- wait_event(fs_info->async_submit_wait,
|
|
|
- (atomic_read(&fs_info->async_delalloc_pages) <
|
|
|
- limit));
|
|
|
- }
|
|
|
-
|
|
|
while (atomic_read(&fs_info->async_submit_draining) &&
|
|
|
atomic_read(&fs_info->async_delalloc_pages)) {
|
|
|
wait_event(fs_info->async_submit_wait,
|