Re: [mm PATCH v5 7/7] mm: Use common iterator for deferred_init_pages and deferred_free_pages

2018-11-12 Thread Alexander Duyck
On 11/9/2018 8:13 PM, Pavel Tatashin wrote: On 18-11-05 13:20:01, Alexander Duyck wrote: +static unsigned long __next_pfn_valid_range(unsigned long *i, + unsigned long end_pfn) { - if (!pfn_valid_within(pfn)) - return false; -

Re: [mm PATCH v5 7/7] mm: Use common iterator for deferred_init_pages and deferred_free_pages

2018-11-09 Thread Pavel Tatashin
On 18-11-05 13:20:01, Alexander Duyck wrote: > +static unsigned long __next_pfn_valid_range(unsigned long *i, > + unsigned long end_pfn) > { > - if (!pfn_valid_within(pfn)) > - return false; > - if (!(pfn & (pageblock_nr_pages - 1)) && !p

[mm PATCH v5 7/7] mm: Use common iterator for deferred_init_pages and deferred_free_pages

2018-11-05 Thread Alexander Duyck
This patch creates a common iterator to be used by both deferred_init_pages and deferred_free_pages. By doing this we can cut down a bit on code overhead as they will likely both be inlined into the same function anyway. This new approach allows deferred_init_pages to make use of __init_pageblock.