diff options
author | Matthew Wilcox (Oracle) <willy@infradead.org> | 2022-05-02 01:47:42 -0400 |
---|---|---|
committer | Matthew Wilcox (Oracle) <willy@infradead.org> | 2022-05-09 23:12:53 -0400 |
commit | 6612ed24a242734560f9643ccb08f2f40b6e144b (patch) | |
tree | 1775d0604d77c36e3eed0697d7f8536c1cb84ff9 /mm | |
parent | aa5dc8c46189779555e491d5a5ae1cc717ead774 (diff) |
secretmem: Convert to free_folio
Prepare for any size of folio, even though secretmem only uses order-0
folios for now.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Diffstat (limited to 'mm')
-rw-r--r-- | mm/secretmem.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/mm/secretmem.c b/mm/secretmem.c index 3b3cf2892b6a..206ed6b40c1d 100644 --- a/mm/secretmem.c +++ b/mm/secretmem.c @@ -145,15 +145,15 @@ static int secretmem_migratepage(struct address_space *mapping, return -EBUSY; } -static void secretmem_freepage(struct page *page) +static void secretmem_free_folio(struct folio *folio) { - set_direct_map_default_noflush(page); - clear_highpage(page); + set_direct_map_default_noflush(&folio->page); + folio_zero_segment(folio, 0, folio_size(folio)); } const struct address_space_operations secretmem_aops = { .dirty_folio = noop_dirty_folio, - .freepage = secretmem_freepage, + .free_folio = secretmem_free_folio, .migratepage = secretmem_migratepage, .isolate_page = secretmem_isolate_page, }; |