Re: [PATCH v1 1/4] mm/compaction: enable compacting >0 order folios.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



>> @@ -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


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux