lkml.org 
[lkml]   [2021]   [Apr]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 04/10] mm/migrate: make migrate_pages() return nr_succeeded
From
Date
On 4/8/21 11:17 AM, Oscar Salvador wrote:
> --- a/mm/page_alloc.c
> +++ b/mm/page_alloc.c
> @@ -8490,7 +8490,8 @@ static int __alloc_contig_migrate_range(struct compact_control *cc,
> cc->nr_migratepages -= nr_reclaimed;
>
> ret = migrate_pages(&cc->migratepages, alloc_migration_target,
> - NULL, (unsigned long)&mtc, cc->mode, MR_CONTIG_RANGE);
> + NULL, (unsigned long)&mtc, cc->mode, MR_CONTIG_RANGE,
> + NULL);
> }
> if (ret < 0) {
> putback_movable_pages(&cc->migratepages);

I also considered passing NULL to mean "I don't care about
nr_succeeded". I mostly avoided it to reduce churn. But, looking at it
here, it does seem cleaner.

Any objections to moving over to Oscar's suggestion?

\
 
 \ /
  Last update: 2021-04-09 17:51    [W:0.114 / U:0.920 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site