Skip to content

Commit dccef48

Browse files
Matthew Wilcox (Oracle)opsiff
authored andcommitted
mm/memory-failure: use folio functions throughout collect_procs()
Saves a couple of calls to compound_head(). Link: https://lkml.kernel.org/r/[email protected] Signed-off-by: Matthew Wilcox (Oracle) <[email protected]> Reviewed-by: Jane Chu <[email protected]> Acked-by: Miaohe Lin <[email protected]> Cc: Dan Williams <[email protected]> Cc: Miaohe Lin <[email protected]> Cc: Oscar Salvador <[email protected]> Signed-off-by: Andrew Morton <[email protected]> (cherry picked from commit 0edb5b2)
1 parent 253e8ea commit dccef48

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

mm/memory-failure.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -722,9 +722,9 @@ static void collect_procs(struct folio *folio, struct page *page,
722722
{
723723
if (!folio->mapping)
724724
return;
725-
if (unlikely(PageKsm(page)))
725+
if (unlikely(folio_test_ksm(folio)))
726726
collect_procs_ksm(page, tokill, force_early);
727-
else if (PageAnon(page))
727+
else if (folio_test_anon(folio))
728728
collect_procs_anon(folio, page, tokill, force_early);
729729
else
730730
collect_procs_file(folio, page, tokill, force_early);

0 commit comments

Comments
 (0)