]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
arm64: __show_regs: Only resolve kernel symbols when running at EL1
authorWill Deacon <will.deacon@arm.com>
Mon, 19 Feb 2018 16:46:57 +0000 (16:46 +0000)
committerWill Deacon <will.deacon@arm.com>
Mon, 19 Feb 2018 17:07:12 +0000 (17:07 +0000)
commita06f818a70de21b4b3b4186816094208fc7accf9
tree4b5ec2e02b5589b5ed8b7541b465c64985ae729d
parent1962682d2b2fbe6cfa995a85c53c069fadda473e
arm64: __show_regs: Only resolve kernel symbols when running at EL1

__show_regs pretty prints PC and LR by attempting to map them to kernel
function names to improve the utility of crash reports. Unfortunately,
this mapping is applied even when the pt_regs corresponds to user mode,
resulting in a KASLR oracle.

Avoid this issue by only looking up the function symbols when the register
state indicates that we're actually running at EL1.

Cc: <stable@vger.kernel.org>
Reported-by: NCSC Security <security@ncsc.gov.uk>
Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm64/kernel/process.c