Commit 8b463be3 authored by Matthew Wilcox (Oracle)'s avatar Matthew Wilcox (Oracle) Committed by Andrew Morton
Browse files

mm: add folio_test_movable()

This is the folio equivalent of PageMovable() which is needed to
convert mm/migrate.c to folios.

Link: https://lkml.kernel.org/r/20220504182857.4013401-26-willy@infradead.org


Signed-off-by: default avatarMatthew Wilcox (Oracle) <willy@infradead.org>
Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent a9595b30
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -105,6 +105,11 @@ static inline void __ClearPageMovable(struct page *page)
}
#endif

static inline bool folio_test_movable(struct folio *folio)
{
	return PageMovable(&folio->page);
}

#ifdef CONFIG_NUMA_BALANCING
extern int migrate_misplaced_page(struct page *page,
				  struct vm_area_struct *vma, int node);