summaryrefslogtreecommitdiff
path: root/mm/truncate.c
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2022-02-13 16:40:24 -0500
committerMatthew Wilcox (Oracle) <willy@infradead.org>2022-03-21 12:59:02 -0400
commit261b6840ed10419ac2f554e515592d59dd5c82cf (patch)
tree4613688e69179573f8f0174340de334ecd58aec0 /mm/truncate.c
parentb4545f46533b7e69cb20e05c9fe987be76e1a3da (diff)
mm: Turn deactivate_file_page() into deactivate_file_folio()
This function has one caller which already has a reference to the page, so we don't need to use get_page_unless_zero(). Also move the prototype to mm/internal.h. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Miaohe Lin <linmiaohe@huawei.com>
Diffstat (limited to 'mm/truncate.c')
-rw-r--r--mm/truncate.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/truncate.c b/mm/truncate.c
index a8b0243eadf6..9ed62cb3c503 100644
--- a/mm/truncate.c
+++ b/mm/truncate.c
@@ -527,7 +527,7 @@ static unsigned long __invalidate_mapping_pages(struct address_space *mapping,
* of interest and try to speed up its reclaim.
*/
if (!ret) {
- deactivate_file_page(&folio->page);
+ deactivate_file_folio(folio);
/* It is likely on the pagevec of a remote CPU */
if (nr_pagevec)
(*nr_pagevec)++;