1
0
Fork 0
alistair23-linux/arch/arm64
Marc Zyngier d96ef8fa95 KVM: arm64: Save the host's PtrAuth keys in non-preemptible context
commit ef3e40a7ea upstream.

When using the PtrAuth feature in a guest, we need to save the host's
keys before allowing the guest to program them. For that, we dump
them in a per-CPU data structure (the so called host context).

But both call sites that do this are in preemptible context,
which may end up in disaster should the vcpu thread get preempted
before reentering the guest.

Instead, save the keys eagerly on each vcpu_load(). This has an
increased overhead, but is at least safe.

Cc: stable@vger.kernel.org
Reviewed-by: Mark Rutland <mark.rutland@arm.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-06-17 16:40:38 +02:00
..
boot arm64: dts: mt8173: fix vcodec-enc clock 2020-06-03 08:21:19 +02:00
configs arm64/ARM: configs: Change CONFIG_REMOTEPROC from m to y 2019-09-30 11:48:00 -07:00
crypto crypto: arch/nhpoly1305 - process in explicit 4k chunks 2020-05-14 07:58:25 +02:00
include KVM: arm64: Save the host's PtrAuth keys in non-preemptible context 2020-06-17 16:40:38 +02:00
kernel arm64: Fix PTRACE_SYSEMU semantics 2020-05-27 17:46:40 +02:00
kvm KVM: arm64: Save the host's PtrAuth keys in non-preemptible context 2020-06-17 16:40:38 +02:00
lib arm64: uaccess: Remove uaccess_*_not_uao asm macros 2019-11-20 18:51:54 +00:00
mm arm64: hugetlb: avoid potential NULL dereference 2020-05-14 07:58:26 +02:00
net arm64: bpf: optimize modulo operation 2019-09-03 15:44:40 +02:00
xen xen/efi: have a common runtime setup function 2019-10-02 10:31:07 -04:00
Kbuild arm64: add arch/arm64/Kbuild 2019-08-21 18:47:15 +01:00
Kconfig arm64: errata: Hide CTR_EL0.DIC on systems affected by Neoverse-N1 #1542419 2020-04-29 16:32:56 +02:00
Kconfig.debug treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00
Kconfig.platforms arm64: exynos: Enable exynos-chipid driver 2019-09-04 22:43:26 +02:00
Makefile arm64: Always force a branch protection mode when the compiler has one 2020-04-17 10:50:23 +02:00