KVM: arm64: Add userspace flag to enable pointer authentication
authorAmit Daniel Kachhap <amit.kachhap@arm.com>
Tue, 23 Apr 2019 04:42:36 +0000 (10:12 +0530)
committerMarc Zyngier <marc.zyngier@arm.com>
Wed, 24 Apr 2019 14:30:40 +0000 (15:30 +0100)
commita22fa321d13b0264976cbbc1d22f4c27c41d3642
tree1f68397998eccf792fa7452d89a00ed6e6350488
parent384b40caa8afae44a54e8f69bd37097c0279fdce
KVM: arm64: Add userspace flag to enable pointer authentication

Now that the building blocks of pointer authentication are present, lets
add userspace flags KVM_ARM_VCPU_PTRAUTH_ADDRESS and
KVM_ARM_VCPU_PTRAUTH_GENERIC. These flags will enable pointer
authentication for the KVM guest on a per-vcpu basis through the ioctl
KVM_ARM_VCPU_INIT.

This features will allow the KVM guest to allow the handling of
pointer authentication instructions or to treat them as undefined
if not set.

Necessary documentations are added to reflect the changes done.

Reviewed-by: Dave Martin <Dave.Martin@arm.com>
Signed-off-by: Amit Daniel Kachhap <amit.kachhap@arm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Marc Zyngier <marc.zyngier@arm.com>
Cc: Christoffer Dall <christoffer.dall@arm.com>
Cc: kvmarm@lists.cs.columbia.edu
Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
Documentation/arm64/pointer-authentication.txt
Documentation/virtual/kvm/api.txt
arch/arm64/include/asm/kvm_host.h
arch/arm64/include/uapi/asm/kvm.h
arch/arm64/kvm/reset.c