Unmap pages before removing them from the page cache.
The new cancel_dirty_pages() code found that XFS was removing
page from the page cache that had dirty page table entries.
XFS invalidates page cache pages via internal interfaces which
are implemented via truncate_inode_pages which does not remove
the page mapping first.
Switch to using invalidate_inode_pages2_range() which does almost
the same thing except it also removes page table mappings as
expected by cancel_dirty_pages.
Date: Thu Jan 11 17:23:10 AEDT 2007
Inspected by: hch@xxxxxxxxxxxxx,lachlan
The following file(s) were checked into:
fs/xfs/linux-2.6/xfs_fs_subr.c - 1.48 - changed
- Convert truncate_inode_pages to invalidate_inode_pages2_range
so that page table mappings are removed before we remove the
pages from the page cache.