mm/mm_init.c: not always search next deferred_init_pfn from very beginning

In function deferred_init_memmap(), we call
deferred_init_mem_pfn_range_in_zone() to get the next deferred_init_pfn.
But we always search it from the very beginning.

Since we save the index in i, we can leverage this to search from i next
time.

[rppt refine the comment]

Signed-off-by: Wei Yang <richard.weiyang@gmail.com>
Link: https://lore.kernel.org/all/20240605071339.15330-1-richard.weiyang@gmail.com
Signed-off-by: Mike Rapoport (IBM) <rppt@kernel.org>
This commit is contained in:
Wei Yang 2024-06-05 07:13:39 +00:00 • committed by Mike Rapoport (IBM)
commit f1180fd2a7
2 changed files with 14 additions and 28 deletions