diff options
author | Pavel Tatashin <[email protected]> | 2018-07-16 11:16:30 -0400 |
---|---|---|
committer | Linus Torvalds <[email protected]> | 2018-07-16 09:41:57 -0700 |
commit | d1b47a7c9efcf3c3384b70f6e3c8f1423b44d8c7 (patch) | |
tree | 1d2fefe2d803db41242df44c15dc8fe7b770edd7 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | 9d3cce1e8b8561fed5f383d22a4d6949db4eadbe (diff) |
mm: don't do zero_resv_unavail if memmap is not allocated
Moving zero_resv_unavail before memmap_init_zone(), caused a regression on
x86-32.
The cause is that we access struct pages before they are allocated when
CONFIG_FLAT_NODE_MEM_MAP is used.
free_area_init_nodes()
zero_resv_unavail()
mm_zero_struct_page(pfn_to_page(pfn)); <- struct page is not alloced
free_area_init_node()
if CONFIG_FLAT_NODE_MEM_MAP
alloc_node_mem_map()
memblock_virt_alloc_node_nopanic() <- struct page alloced here
On the other hand memblock_virt_alloc_node_nopanic() zeroes all the memory
that it returns, so we do not need to do zero_resv_unavail() here.
Fixes: e181ae0c5db9 ("mm: zero unavailable pages before memmap init")
Signed-off-by: Pavel Tatashin <[email protected]>
Tested-by: Matt Hart <[email protected]>
Acked-by: Michal Hocko <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions