summaryrefslogtreecommitdiff
path: root/mm/filemap.c
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2021-06-25 09:27:04 -0400
committerMatthew Wilcox (Oracle) <willy@infradead.org>2021-09-27 09:27:31 -0400
commit8f425e4ed0eb3ef0b2d85a9efccf947ca6aa9b1c (patch)
tree4fb8ccee7ba7f7f6895939375098cc4cdaba2ea7 /mm/filemap.c
parent118f2875490b027218594db9e2effb52cebc7693 (diff)
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/filemap.c')
-rw-r--r--mm/filemap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/filemap.c b/mm/filemap.c
index d74be9fb3aa2..816af226f49d 100644
--- a/mm/filemap.c
+++ b/mm/filemap.c
@@ -889,7 +889,7 @@ noinline int __add_to_page_cache_locked(struct page *page,
page->index = offset;
if (!huge) {
- error = mem_cgroup_charge(page, NULL, gfp);
+ error = mem_cgroup_charge(page_folio(page), NULL, gfp);
if (error)
goto error;
charged = true;