arm64: arch_timer: Add workaround for ARM erratum 1188873
authorMarc Zyngier <marc.zyngier@arm.com>
Wed, 6 Apr 2022 16:45:19 +0000 (17:45 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 12 Apr 2022 05:52:15 +0000 (07:52 +0200)
commit501d9435c7161ccc693381e4753d4b895665370a
tree3ea07643434c6786240f42f09d248c49cc3ada0f
parentba072295630fece57622f60b73756064bbaee26e
arm64: arch_timer: Add workaround for ARM erratum 1188873

commit 95b861a4a6d94f64d5242605569218160ebacdbe upstream.

When running on Cortex-A76, a timer access from an AArch32 EL0
task may end up with a corrupted value or register. The workaround for
this is to trap these accesses at EL1/EL2 and execute them there.

This only affects versions r0p0, r1p0 and r2p0 of the CPU.

Acked-by: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: James Morse <james.morse@arm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/arm64/Kconfig
arch/arm64/include/asm/cpucaps.h
arch/arm64/include/asm/cputype.h
arch/arm64/kernel/cpu_errata.c
drivers/clocksource/arm_arch_timer.c