summaryrefslogtreecommitdiffstats
path: root/fs/btrfs/extent_io.c
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2008-11-10 17:50:50 +0100
committerChris Mason <chris.mason@oracle.com>2008-11-10 17:50:50 +0100
commit39be25cd89450940b0e5f8a6aad71d1ec99b17bf (patch)
treeecd9732a647df1af7439e1f859ac3b00e68cb430 /fs/btrfs/extent_io.c
parentBtrfs: Try harder while searching for free space (diff)
downloadlinux-39be25cd89450940b0e5f8a6aad71d1ec99b17bf.tar.xz
linux-39be25cd89450940b0e5f8a6aad71d1ec99b17bf.zip
Btrfs: Use invalidatepage when writepage finds a page outside of i_size
With all the recent fixes to the delalloc locking, it is now safe again to use invalidatepage inside the writepage code for pages outside of i_size. This used to deadlock against some of the code to write locked ranges of pages, but all of that has been fixed. Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/extent_io.c')
-rw-r--r--fs/btrfs/extent_io.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c
index 69ea09659d47..af2d9a9300a7 100644
--- a/fs/btrfs/extent_io.c
+++ b/fs/btrfs/extent_io.c
@@ -2174,11 +2174,7 @@ static int __extent_writepage(struct page *page, struct writeback_control *wbc,
pg_offset = i_size & (PAGE_CACHE_SIZE - 1);
if (page->index > end_index ||
(page->index == end_index && !pg_offset)) {
- if (epd->extent_locked) {
- if (tree->ops && tree->ops->writepage_end_io_hook)
- tree->ops->writepage_end_io_hook(page, start,
- page_end, NULL, 1);
- }
+ page->mapping->a_ops->invalidatepage(page, 0);
unlock_page(page);
return 0;
}