]> git.baikalelectronics.ru Git - kernel.git/commit
mm/memory_hotplug: use helper function zone_end_pfn() to get end_pfn
authorMiaohe Lin <linmiaohe@huawei.com>
Fri, 26 Feb 2021 01:17:21 +0000 (17:17 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 26 Feb 2021 17:41:00 +0000 (09:41 -0800)
commit7085a68a891525033bbc85db2a1c795dece43dad
tree670664e7944284862e5c1ccfbc63e5eafe88c0db
parent22d690cd5081c2a220f82052e35e2036ef078899
mm/memory_hotplug: use helper function zone_end_pfn() to get end_pfn

Commit 3774da55a016 ("mm: add & use zone_end_pfn() and zone_spans_pfn()")
introduced the helper zone_end_pfn() to calculate the zone end pfn.  But
update_pgdat_span() forgot to use it.

Use this helper and rename local variable zone_end_pfn to end_pfn to avoid
a naming conflict with the existing zone_end_pfn().

Link: https://lkml.kernel.org/r/20210127093211.37714-1-linmiaohe@huawei.com
Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
Reviewed-by: David Hildenbrand <david@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
mm/memory_hotplug.c