>> @@ -1144,17 +1166,18 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn, >> goto isolate_abort; >> } >> } >> + } >> - /* >> - * folio become large since the non-locked check, >> - * and it's on LRU. >> - */ >> - if (unlikely(folio_test_large(folio) && !cc->alloc_contig)) { >> - low_pfn += folio_nr_pages(folio) - 1; >> - nr_scanned += folio_nr_pages(folio) - 1; >> - folio_set_lru(folio); >> - goto isolate_fail_put; >> - } >> + /* >> + * Check LRU folio order under the lock >> + */ >> + if (unlikely(skip_isolation_on_order(folio_order(folio), >> + cc->order) && >> + !cc->alloc_contig)) { >> + low_pfn += folio_nr_pages(folio) - 1; >> + nr_scanned += folio_nr_pages(folio) - 1; >> + folio_set_lru(folio); >> + goto isolate_fail_put; >> } > > Why was this part moved out of the 'if (lruvec != locked)' block? If we hold the lru lock, then we do not need to check again, right? Probably I messed this up during rebase. Thank you for pointing this out. Will fix it in the next version. -- Best Regards, Yan, Zi
Attachment:
signature.asc
Description: OpenPGP digital signature