lkml.org 
[lkml]   [2021]   [Mar]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v5 5/5] mm,page_alloc: Drop unnecessary checks from pfn_range_valid_contig
On Wed, Mar 17, 2021 at 04:03:06PM +0100, Michal Hocko wrote:
> > alloc_contig_pages() vs. alloc_contig_range(). The patches are active for
> > virtio-mem and CMA AFAIKS.
>
> yeah, I meant to say "are not actually fully active".

We could place this patch earlier in this patchset.
The only thing is that we would lose the prevalidation (at leat for
HugeTLB page) which is done upfront to find later on that we do not
support hugetlb handling in isolate_migratepates_block.
So the bad thing about placing it earlier, is that wrt. hugetlb pages,
alloc_gigantic_page will take longer to fail (when we already know that
will fail).

Then we have the page_count check, which is also racy and
isolate_migratepages_block will take care of it.
So I guess can think of this patch as a preparatory patch that removes racy
checks that will be re-checked later on in the end function which does
the actual handling.

What do you think?

--
Oscar Salvador
SUSE L3

\
 
 \ /
  Last update: 2021-03-18 09:47    [W:0.088 / U:0.468 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site