arm64: mm: print out correct page table entries
authorKristina Martsenko <kristina.martsenko@arm.com>
Fri, 9 Jun 2017 15:35:52 +0000 (16:35 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 8 May 2019 05:19:07 +0000 (07:19 +0200)
commit9cec5be38780b94fdeebfa9b9803c90327ed9656
tree724739291d6a12b5e463e914395fd3084593fac1
parent5d01a64da40355b3274f0f7f746019809184b72c
arm64: mm: print out correct page table entries

commit 67ce16ec15ce9d97d3d85e72beabbc5d7017193e upstream.

When we take a fault that can't be handled, we print out the page table
entries associated with the faulting address. In some cases we currently
print out the wrong entries. For a faulting TTBR1 address, we sometimes
print out TTBR0 table entries instead, and for a faulting TTBR0 address
we sometimes print out TTBR1 table entries. Fix this by choosing the
tables based on the faulting address.

Acked-by: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Kristina Martsenko <kristina.martsenko@arm.com>
[will: zero-extend addrs to 64-bit, don't walk swapper w/ TTBR0 addr]
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Andrey Konovalov <andreyknvl@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/arm64/include/asm/system_misc.h
arch/arm64/mm/fault.c