Skip to content

Commit 1ff5c8e

Browse files
Kefeng Wangmpe
authored andcommitted
Revert "powerpc: Set max_mapnr correctly"
This reverts commit 602946e. If CONFIG_HIGHMEM is enabled, no highmem will be added with max_mapnr set to max_low_pfn, see mem_init(): for (pfn = highmem_mapnr; pfn < max_mapnr; ++pfn) { ... free_highmem_page(); } Now that virt_addr_valid() has been fixed in the previous commit, we can revert the change to max_mapnr. Fixes: 602946e ("powerpc: Set max_mapnr correctly") Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com> Reviewed-by: Christophe Leroy <christophe.leroy@csgroup.eu> Reported-by: Erhard F. <erhard_f@mailbox.org> [mpe: Update change log to reflect series reordering] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/20220406145802.538416-2-mpe@ellerman.id.au
1 parent ffa0b64 commit 1ff5c8e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

arch/powerpc/mm/mem.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ void __init mem_init(void)
255255
#endif
256256

257257
high_memory = (void *) __va(max_low_pfn * PAGE_SIZE);
258-
set_max_mapnr(max_low_pfn);
258+
set_max_mapnr(max_pfn);
259259

260260
kasan_late_init();
261261

0 commit comments

Comments
 (0)