Skip to content

Commit

Permalink
powerpc: Don't flush caches when adding memory
Browse files Browse the repository at this point in the history
This operation takes a significant amount of time when hotplugging
large amounts of memory (~50 seconds with 890GB of persistent memory).

This was orignally in commit fb5924f
("powerpc/mm: Flush cache on memory hot(un)plug") to support memtrace,
but the flush on add is not needed as it is flushed on remove.

Signed-off-by: Alastair D'Silva <alastair@d-silva.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20191104023305.9581-7-alastair@au1.ibm.com
  • Loading branch information
Alastair D'Silva authored and Michael Ellerman committed Nov 7, 2019
1 parent 0762659 commit ea458ef
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions arch/powerpc/mm/mem.c
Original file line number Diff line number Diff line change
Expand Up @@ -142,8 +142,6 @@ int __ref arch_add_memory(int nid, u64 start, u64 size,
return -EFAULT;
}

flush_dcache_range_chunked(start, start + size, FLUSH_CHUNK_SIZE);

return __add_pages(nid, start_pfn, nr_pages, restrictions);
}

Expand Down

0 comments on commit ea458ef

Please sign in to comment.