]> git.baikalelectronics.ru Git - kernel.git/commit
perf: arm_spe: Fail device probe when arm64_kernel_unmapped_at_el0()
authorWill Deacon <will.deacon@arm.com>
Mon, 27 Nov 2017 15:49:53 +0000 (15:49 +0000)
committerWill Deacon <will.deacon@arm.com>
Mon, 11 Dec 2017 13:41:13 +0000 (13:41 +0000)
commit0bec7cf280287ada0594db53f48bd7d5c6955db1
tree0d82f6fa778dd826c1e448f56e6bcbbdf9e2be89
parente91b286b1d43a2d9bf101b3b685eaa4fd89bad54
perf: arm_spe: Fail device probe when arm64_kernel_unmapped_at_el0()

When running with the kernel unmapped whilst at EL0, the virtually-addressed
SPE buffer is also unmapped, which can lead to buffer faults if userspace
profiling is enabled and potentially also when writing back kernel samples
unless an expensive drain operation is performed on exception return.

For now, fail the SPE driver probe when arm64_kernel_unmapped_at_el0().

Reviewed-by: Mark Rutland <mark.rutland@arm.com>
Tested-by: Laura Abbott <labbott@redhat.com>
Tested-by: Shanker Donthineni <shankerd@codeaurora.org>
Signed-off-by: Will Deacon <will.deacon@arm.com>
drivers/perf/arm_spe_pmu.c