diff options
-rw-r--r-- | init/main.c | 3 | ||||
-rw-r--r-- | mm/page_ext.c | 4 |
2 files changed, 3 insertions, 4 deletions
diff --git a/init/main.c b/init/main.c index e2e80ca3165a..c86a1c8f19f4 100644 --- a/init/main.c +++ b/init/main.c | |||
@@ -695,7 +695,6 @@ asmlinkage __visible void __init start_kernel(void) | |||
695 | initrd_start = 0; | 695 | initrd_start = 0; |
696 | } | 696 | } |
697 | #endif | 697 | #endif |
698 | page_ext_init(); | ||
699 | kmemleak_init(); | 698 | kmemleak_init(); |
700 | setup_per_cpu_pageset(); | 699 | setup_per_cpu_pageset(); |
701 | numa_policy_init(); | 700 | numa_policy_init(); |
@@ -1131,6 +1130,8 @@ static noinline void __init kernel_init_freeable(void) | |||
1131 | sched_init_smp(); | 1130 | sched_init_smp(); |
1132 | 1131 | ||
1133 | page_alloc_init_late(); | 1132 | page_alloc_init_late(); |
1133 | /* Initialize page ext after all struct pages are initialized. */ | ||
1134 | page_ext_init(); | ||
1134 | 1135 | ||
1135 | do_basic_setup(); | 1136 | do_basic_setup(); |
1136 | 1137 | ||
diff --git a/mm/page_ext.c b/mm/page_ext.c index ae44f7adbe07..8c78b8d45117 100644 --- a/mm/page_ext.c +++ b/mm/page_ext.c | |||
@@ -398,10 +398,8 @@ void __init page_ext_init(void) | |||
398 | * We know some arch can have a nodes layout such as | 398 | * We know some arch can have a nodes layout such as |
399 | * -------------pfn--------------> | 399 | * -------------pfn--------------> |
400 | * N0 | N1 | N2 | N0 | N1 | N2|.... | 400 | * N0 | N1 | N2 | N0 | N1 | N2|.... |
401 | * | ||
402 | * Take into account DEFERRED_STRUCT_PAGE_INIT. | ||
403 | */ | 401 | */ |
404 | if (early_pfn_to_nid(pfn) != nid) | 402 | if (pfn_to_nid(pfn) != nid) |
405 | continue; | 403 | continue; |
406 | if (init_section_page_ext(pfn, nid)) | 404 | if (init_section_page_ext(pfn, nid)) |
407 | goto oom; | 405 | goto oom; |