File tree 1 file changed +6
-6
lines changed
1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -984,19 +984,19 @@ static void __init memmap_init(void)
984
984
}
985
985
}
986
986
987
- #ifdef CONFIG_SPARSEMEM
988
987
/*
989
988
* Initialize the memory map for hole in the range [memory_end,
990
- * section_end].
989
+ * section_end] for SPARSEMEM and in the range [memory_end, memmap_end]
990
+ * for FLATMEM.
991
991
* Append the pages in this hole to the highest zone in the last
992
992
* node.
993
- * The call to init_unavailable_range() is outside the ifdef to
994
- * silence the compiler warining about zone_id set but not used;
995
- * for FLATMEM it is a nop anyway
996
993
*/
994
+ #ifdef CONFIG_SPARSEMEM
997
995
end_pfn = round_up (end_pfn , PAGES_PER_SECTION );
998
- if (hole_pfn < end_pfn )
996
+ #else
997
+ end_pfn = round_up (end_pfn , MAX_ORDER_NR_PAGES );
999
998
#endif
999
+ if (hole_pfn < end_pfn )
1000
1000
init_unavailable_range (hole_pfn , end_pfn , zone_id , nid );
1001
1001
}
1002
1002
You can’t perform that action at this time.
0 commit comments