hw/arm/virt: KVM: Enable PAuth when supported by the host
authorMarc Zyngier <maz@kernel.org>
Fri, 7 Jan 2022 15:01:54 +0000 (15:01 +0000)
committerPeter Maydell <peter.maydell@linaro.org>
Thu, 20 Jan 2022 11:47:52 +0000 (11:47 +0000)
commit95ea96e8b1610f2d1bfa2abd0d12c40d647e563d
tree23bb54cdc5dd3a38cdc7b1c8889807bce2a1d765
parentb10d00d8811fa4eed4862963273d7353ce310c82
hw/arm/virt: KVM: Enable PAuth when supported by the host

Add basic support for Pointer Authentication when running a KVM
guest and that the host supports it, loosely based on the SVE
support.

Although the feature is enabled by default when the host advertises
it, it is possible to disable it by setting the 'pauth=off' CPU
property. The 'pauth' comment is removed from cpu-features.rst,
as it is now common to both TCG and KVM.

Tested on an Apple M1 running 5.16-rc6.

Cc: Eric Auger <eric.auger@redhat.com>
Cc: Richard Henderson <richard.henderson@linaro.org>
Cc: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Andrew Jones <drjones@redhat.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-id: 20220107150154.2490308-1-maz@kernel.org
[PMM: fixed indentation]
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
docs/system/arm/cpu-features.rst
target/arm/cpu.c
target/arm/cpu.h
target/arm/cpu64.c
target/arm/kvm64.c