KVM: arm-vgic: Add vgic reg access from dev attr
authorChristoffer Dall <christoffer.dall@linaro.org>
Fri, 25 Oct 2013 20:17:31 +0000 (21:17 +0100)
committerChristoffer Dall <christoffer.dall@linaro.org>
Thu, 2 Oct 2014 15:18:26 +0000 (17:18 +0200)
commit0b3a540dcc4087698c95c6d1bda4071424283345
tree4f61bc7c78a3f409f038ea39c40412d9007d900d
parentf05c65c6daf2d2c33c31ddc3b48df2693f8e9594
KVM: arm-vgic: Add vgic reg access from dev attr

Add infrastructure to handle distributor and cpu interface register
accesses through the KVM_{GET/SET}_DEVICE_ATTR interface by adding the
KVM_DEV_ARM_VGIC_GRP_DIST_REGS and KVM_DEV_ARM_VGIC_GRP_CPU_REGS groups
and defining the semantics of the attr field to be the MMIO offset as
specified in the GICv2 specs.

Missing register accesses or other changes in individual register access
functions to support save/restore of the VGIC state is added in
subsequent patches.

Acked-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
(cherry picked from commit c07a0191ef2de1f9510f12d1f88e3b0b5cd8d66f)
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
Documentation/virtual/kvm/devices/arm-vgic.txt
arch/arm/include/uapi/asm/kvm.h
virt/kvm/arm/vgic.c