diff options
author | Christoffer Dall <christoffer.dall@linaro.org> | 2015-08-30 08:45:20 -0400 |
---|---|---|
committer | Christoffer Dall <christoffer.dall@linaro.org> | 2015-10-22 17:01:43 -0400 |
commit | 54723bb37feac347a169359536f3dff122cabca3 (patch) | |
tree | 80f6593a7634deb7b0c28cb2c8d7e3e303b3395c /virt | |
parent | 8bf9a701e103fd17dbdf0355e43ff5200b4823aa (diff) |
arm/arm64: KVM: Use appropriate define in VGIC reset code
We currently initialize the SGIs to be enabled in the VGIC code, but we
use the VGIC_NR_PPIS define for this purpose, instead of the the more
natural VGIC_NR_SGIS. Change this slightly confusing use of the
defines.
Note: This should have no functional change, as both names are defined
to the number 16.
Acked-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
Diffstat (limited to 'virt')
-rw-r--r-- | virt/kvm/arm/vgic.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/virt/kvm/arm/vgic.c b/virt/kvm/arm/vgic.c index f8ca2e9d2f0b..a44ecf9eca4e 100644 --- a/virt/kvm/arm/vgic.c +++ b/virt/kvm/arm/vgic.c | |||
@@ -2128,8 +2128,12 @@ int vgic_init(struct kvm *kvm) | |||
2128 | break; | 2128 | break; |
2129 | } | 2129 | } |
2130 | 2130 | ||
2131 | for (i = 0; i < dist->nr_irqs; i++) { | 2131 | /* |
2132 | if (i < VGIC_NR_PPIS) | 2132 | * Enable all SGIs and configure all private IRQs as |
2133 | * edge-triggered. | ||
2134 | */ | ||
2135 | for (i = 0; i < VGIC_NR_PRIVATE_IRQS; i++) { | ||
2136 | if (i < VGIC_NR_SGIS) | ||
2133 | vgic_bitmap_set_irq_val(&dist->irq_enabled, | 2137 | vgic_bitmap_set_irq_val(&dist->irq_enabled, |
2134 | vcpu->vcpu_id, i, 1); | 2138 | vcpu->vcpu_id, i, 1); |
2135 | if (i < VGIC_NR_PRIVATE_IRQS) | 2139 | if (i < VGIC_NR_PRIVATE_IRQS) |