summaryrefslogtreecommitdiffstats
path: root/mm/userfaultfd.c
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2021-06-25 15:27:04 +0200
committerMatthew Wilcox (Oracle) <willy@infradead.org>2021-09-27 15:27:31 +0200
commit8f425e4ed0eb3ef0b2d85a9efccf947ca6aa9b1c (patch)
tree4fb8ccee7ba7f7f6895939375098cc4cdaba2ea7 /mm/userfaultfd.c
parentmm/memcg: Convert commit_charge() to take a folio (diff)
downloadlinux-8f425e4ed0eb3ef0b2d85a9efccf947ca6aa9b1c.tar.xz
linux-8f425e4ed0eb3ef0b2d85a9efccf947ca6aa9b1c.zip
mm/memcg: Convert mem_cgroup_charge() to take a folio
Convert all callers of mem_cgroup_charge() to call page_folio() on the page they're currently passing in. Many of them will be converted to use folios themselves soon. Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: David Howells <dhowells@redhat.com> Acked-by: Vlastimil Babka <vbabka@suse.cz>
Diffstat (limited to 'mm/userfaultfd.c')
-rw-r--r--mm/userfaultfd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/userfaultfd.c b/mm/userfaultfd.c
index 7a9008415534..36e5f6ab976f 100644
--- a/mm/userfaultfd.c
+++ b/mm/userfaultfd.c
@@ -164,7 +164,7 @@ static int mcopy_atomic_pte(struct mm_struct *dst_mm,
__SetPageUptodate(page);
ret = -ENOMEM;
- if (mem_cgroup_charge(page, dst_mm, GFP_KERNEL))
+ if (mem_cgroup_charge(page_folio(page), dst_mm, GFP_KERNEL))
goto out_release;
ret = mfill_atomic_install_pte(dst_mm, dst_pmd, dst_vma, dst_addr,