diff options
author | Eric Auger <eric.auger@linaro.org> | 2015-12-21 20:09:38 +0300 |
---|---|---|
committer | Christoffer Dall <christoffer.dall@linaro.org> | 2016-05-20 16:40:06 +0300 |
commit | ad275b8bb1e659b14120174d87e3c1fdc22e9978 (patch) | |
tree | 78bbd8ed5653836ccd931323819ec1f57b793573 /virt/kvm/arm/vgic/vgic.c | |
parent | 5e6431da8f3a04759ac8d77b7c98eec0de580343 (diff) | |
download | linux-ad275b8bb1e659b14120174d87e3c1fdc22e9978.tar.xz |
KVM: arm/arm64: vgic-new: vgic_init: implement vgic_init
This patch allocates and initializes the data structures used
to model the vgic distributor and virtual cpu interfaces. At that
stage the number of IRQs and number of virtual CPUs is frozen.
Signed-off-by: Eric Auger <eric.auger@linaro.org>
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Reviewed-by: Christoffer Dall <christoffer.dall@linaro.org>
Diffstat (limited to 'virt/kvm/arm/vgic/vgic.c')
-rw-r--r-- | virt/kvm/arm/vgic/vgic.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/virt/kvm/arm/vgic/vgic.c b/virt/kvm/arm/vgic/vgic.c index 12ae84b4931f..331885528ead 100644 --- a/virt/kvm/arm/vgic/vgic.c +++ b/virt/kvm/arm/vgic/vgic.c @@ -257,6 +257,10 @@ static int vgic_update_irq_pending(struct kvm *kvm, int cpuid, trace_vgic_update_irq_pending(cpuid, intid, level); + ret = vgic_lazy_init(kvm); + if (ret) + return ret; + vcpu = kvm_get_vcpu(kvm, cpuid); if (!vcpu && intid < VGIC_NR_PRIVATE_IRQS) return -EINVAL; |