summaryrefslogtreecommitdiffstats
path: root/mm/memory_hotplug.c
diff options
context:
space:
mode:
authorKefeng Wang <wangkefeng.wang@huawei.com>2022-07-26 15:11:35 +0200
committerakpm <akpm@linux-foundation.org>2022-07-30 03:07:20 +0200
commit07252dfea2c7089bca68949710268cbbb0ce509e (patch)
treef8b2fbb40b898fa03c05250cf83866560b5df8e3 /mm/memory_hotplug.c
parenthugetlbfs: fix inaccurate comment in hugetlbfs_statfs() (diff)
downloadlinux-07252dfea2c7089bca68949710268cbbb0ce509e.tar.xz
linux-07252dfea2c7089bca68949710268cbbb0ce509e.zip
mm: use is_zone_movable_page() helper
Use is_zone_movable_page() helper to simplify code. Link: https://lkml.kernel.org/r/20220726131135.146912-1-wangkefeng.wang@huawei.com Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Reviewed-by: David Hildenbrand <david@redhat.com> Reviewed-by: Pankaj Gupta <pankaj.gupta@amd.com> Acked-by: Jason Wang <jasowang@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'mm/memory_hotplug.c')
-rw-r--r--mm/memory_hotplug.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c
index 99ecb2b3ff53..fad6d1f2262a 100644
--- a/mm/memory_hotplug.c
+++ b/mm/memory_hotplug.c
@@ -932,7 +932,7 @@ static struct zone *auto_movable_zone_for_pfn(int nid,
if (!page)
continue;
/* If anything is !MOVABLE online the rest !MOVABLE. */
- if (page_zonenum(page) != ZONE_MOVABLE)
+ if (!is_zone_movable_page(page))
goto kernel_zone;
online_pages += PAGES_PER_SECTION;
}