mirror of
https://github.com/torvalds/linux.git
synced 2024-11-10 14:11:52 +00:00
mm: debug check for the fault vs invalidate race
Add a bugcheck for Andrea's pagefault vs invalidate race. This is triggerable for both linear and nonlinear pages with a userspace test harness (using direct IO and truncate, respectively). Signed-off-by: Nick Piggin <npiggin@suse.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
f96efd585b
commit
45426812d6
@ -120,6 +120,7 @@ void __remove_from_page_cache(struct page *page)
|
||||
page->mapping = NULL;
|
||||
mapping->nrpages--;
|
||||
__dec_zone_page_state(page, NR_FILE_PAGES);
|
||||
BUG_ON(page_mapped(page));
|
||||
}
|
||||
|
||||
void remove_from_page_cache(struct page *page)
|
||||
|
Loading…
Reference in New Issue
Block a user