summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2022-02-01 23:33:08 -0500
committerMatthew Wilcox (Oracle) <willy@infradead.org>2022-03-21 13:01:35 -0400
commit9595d76942b8714627d670a7e7ae543812c731ae (patch)
treefebd0a334505f4e11fcd427b96e740ab0548a3cc /include
parentc8423186078312d344474bcb9e2b1ce0a78dbde4 (diff)
mm/rmap: Turn page_lock_anon_vma_read() into folio_lock_anon_vma_read()
Add back page_lock_anon_vma_read() as a wrapper. This saves a few calls to compound_head(). If any callers were passing a tail page before, this would have failed to lock the anon VMA as page->mapping is not valid for tail pages. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/rmap.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/rmap.h b/include/linux/rmap.h
index 21af80d5b711..be020d38b0a5 100644
--- a/include/linux/rmap.h
+++ b/include/linux/rmap.h
@@ -267,6 +267,7 @@ void remove_migration_ptes(struct folio *src, struct folio *dst, bool locked);
* Called by memory-failure.c to kill processes.
*/
struct anon_vma *page_lock_anon_vma_read(struct page *page);
+struct anon_vma *folio_lock_anon_vma_read(struct folio *folio);
void page_unlock_anon_vma_read(struct anon_vma *anon_vma);
int page_mapped_in_vma(struct page *page, struct vm_area_struct *vma);