OSDN Git Service

arm64: Rewrite Spectre-v2 mitigation code
authorWill Deacon <will@kernel.org>
Tue, 15 Sep 2020 22:30:17 +0000 (23:30 +0100)
committerWill Deacon <will@kernel.org>
Tue, 29 Sep 2020 15:08:15 +0000 (16:08 +0100)
commitd4647f0a2ad711101067cba69c34716758aa1e48
treef65d9fa7399f261dbf6d9a11019e2594e4d80047
parent455697adefdb8604cd10413da37c60014aecbbb7
arm64: Rewrite Spectre-v2 mitigation code

The Spectre-v2 mitigation code is pretty unwieldy and hard to maintain.
This is largely due to it being written hastily, without much clue as to
how things would pan out, and also because it ends up mixing policy and
state in such a way that it is very difficult to figure out what's going
on.

Rewrite the Spectre-v2 mitigation so that it clearly separates state from
policy and follows a more structured approach to handling the mitigation.

Signed-off-by: Will Deacon <will@kernel.org>
arch/arm64/include/asm/cpufeature.h
arch/arm64/include/asm/kvm_host.h
arch/arm64/include/asm/processor.h
arch/arm64/include/asm/spectre.h [new file with mode: 0644]
arch/arm64/kernel/cpu_errata.c
arch/arm64/kernel/proton-pack.c
arch/arm64/kvm/hypercalls.c
arch/arm64/kvm/psci.c