summaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorMatthew Wilcox (Oracle) <willy@infradead.org>2023-08-22 22:23:35 +0200
committerAndrew Morton <akpm@linux-foundation.org>2023-08-25 01:20:31 +0200
commit8f9ff2deb8b91ad1cba666c7adbe4ca79e2d3225 (patch)
tree7ccd50ea802f90c07ca26d685a7104a5f0835da6 /mm
parentnios2: fix flush_dcache_page() for usage from irq context (diff)
downloadlinux-8f9ff2deb8b91ad1cba666c7adbe4ca79e2d3225.tar.xz
linux-8f9ff2deb8b91ad1cba666c7adbe4ca79e2d3225.zip
secretmem: convert page_is_secretmem() to folio_is_secretmem()
The only caller already has a folio, so use it to save calling compound_head() in PageLRU() and remove a use of page->mapping. Link: https://lkml.kernel.org/r/20230822202335.179081-1-willy@infradead.org Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org> Reviewed-by: Mike Rapoport (IBM) <rppt@kernel.org> Reviewed-by: David Hildenbrand <david@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r--mm/gup.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/gup.c b/mm/gup.c
index ee4fc15ce88e..948f3b454b00 100644
--- a/mm/gup.c
+++ b/mm/gup.c
@@ -2600,7 +2600,7 @@ static int gup_pte_range(pmd_t pmd, pmd_t *pmdp, unsigned long addr,
if (!folio)
goto pte_unmap;
- if (unlikely(page_is_secretmem(page))) {
+ if (unlikely(folio_is_secretmem(folio))) {
gup_put_folio(folio, 1, flags);
goto pte_unmap;
}