]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit - arch/arm64/kernel/cpu_errata.c
arm64: Implement branch predictor hardening for affected Cortex-A CPUs
authorWill Deacon <will.deacon@arm.com>
Wed, 3 Jan 2018 12:46:21 +0000 (12:46 +0000)
committerKhalid Elmously <khalid.elmously@canonical.com>
Tue, 27 Feb 2018 16:33:14 +0000 (11:33 -0500)
commitf2f427ad94da5fd2defe08520ade876bac5e5360
treeda40f1ed88edfb1119973866c310392bd7e04b8e
parent1fffeab252b3066171a7b8c54c48a1a262ae7b09
arm64: Implement branch predictor hardening for affected Cortex-A CPUs

Commit aa6acde65e03 upstream.

Cortex-A57, A72, A73 and A75 are susceptible to branch predictor aliasing
and can theoretically be attacked by malicious code.

This patch implements a PSCI-based mitigation for these CPUs when available.
The call into firmware will invalidate the branch predictor state, preventing
any malicious entries from affecting other victim contexts.

Co-developed-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
(cherry picked from commit 48993dfa1af8c719576a18c0e2ca1d611297e34e)

CVE-2017-5753
CVE-2017-5715
CVE-2017-5754

Signed-off-by: Paolo Pisati <paolo.pisati@canonical.com>
Acked-by: Brad Figg <brad.figg@canonical.com>
Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
Signed-off-by: Khalid Elmously <khalid.elmously@canonical.com>
arch/arm64/kernel/bpi.S
arch/arm64/kernel/cpu_errata.c