mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
mm: move clearing of page->mapping to page_cache_tree_delete()
Clearing of page->mapping makes sense in page_cache_tree_delete() as well and it will help us with batching things this way. Link: http://lkml.kernel.org/r/[email protected] Signed-off-by: Jan Kara <[email protected]> Acked-by: Mel Gorman <[email protected]> Reviewed-by: Andi Kleen <[email protected]> Cc: Dave Chinner <[email protected]> Cc: Dave Hansen <[email protected]> Cc: "Kirill A. Shutemov" <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
76253fbc8f
commit
2300638b12
1 changed files with 3 additions and 3 deletions
|
|
@ -165,6 +165,9 @@ static void page_cache_tree_delete(struct address_space *mapping,
|
|||
workingset_update_node, mapping);
|
||||
}
|
||||
|
||||
page->mapping = NULL;
|
||||
/* Leave page->index set: truncation lookup relies upon it */
|
||||
|
||||
if (shadow) {
|
||||
mapping->nrexceptional += nr;
|
||||
/*
|
||||
|
|
@ -250,9 +253,6 @@ void __delete_from_page_cache(struct page *page, void *shadow)
|
|||
inode_to_wb(mapping->host));
|
||||
}
|
||||
page_cache_tree_delete(mapping, page, shadow);
|
||||
|
||||
page->mapping = NULL;
|
||||
/* Leave page->index set: truncation lookup relies upon it */
|
||||
}
|
||||
|
||||
static void page_cache_free_page(struct address_space *mapping,
|
||||
|
|
|
|||
Loading…
Reference in a new issue