提交 e3a466b2 编写于 作者: J Jiang Liu 提交者: Linus Torvalds

mm/SH: prepare for killing free_all_bootmem_node()

Prepare for killing free_all_bootmem_node() by using free_all_bootmem().
Signed-off-by: NJiang Liu <jiang.liu@huawei.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Wen Congyang <wency@cn.fujitsu.com>
Cc: Tang Chen <tangchen@cn.fujitsu.com>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
上级 602ddc70
......@@ -412,19 +412,11 @@ void __init mem_init(void)
iommu_init();
high_memory = NULL;
for_each_online_pgdat(pgdat)
high_memory = max_t(void *, high_memory,
__va(pgdat_end_pfn(pgdat) << PAGE_SHIFT));
for_each_online_pgdat(pgdat) {
void *node_high_memory;
if (pgdat->node_spanned_pages)
free_all_bootmem_node(pgdat);
node_high_memory = (void *)__va((pgdat->node_start_pfn +
pgdat->node_spanned_pages) <<
PAGE_SHIFT);
if (node_high_memory > high_memory)
high_memory = node_high_memory;
}
free_all_bootmem();
/* Set this up early, so we can take care of the zero page */
cpu_cache_init();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册