]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/mm: Fix hash table dump when memory is not contiguous
authorRashmica Gupta <rashmica.g@gmail.com>
Mon, 10 Apr 2017 02:04:04 +0000 (12:04 +1000)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 12 Apr 2017 13:03:32 +0000 (23:03 +1000)
commit655535ded08e2bf8e3b86cc70a8971f1039ab31a
treeb2908e912be6a81fc35c3daeb94e2a749522b14e
parenta97f495398bcb375ab5ba45a98c59de537bc1f8c
powerpc/mm: Fix hash table dump when memory is not contiguous

The current behaviour of the hash table dump assumes that memory is contiguous
and iterates from the start of memory to (start + size of memory). When memory
isn't physically contiguous, this doesn't work.

If memory exists at 0-5 GB and 6-10 GB then the current approach will check if
entries exist in the hash table from 0GB to 9GB. This patch changes the
behaviour to iterate over any holes up to the end of memory.

Fixes: 37c505cbf12f ("powerpc/mm: Dump hash table")
Signed-off-by: Rashmica Gupta <rashmica.g@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/mm/dump_hashpagetable.c