KVM: ARM: vgic: Fix sgi dispatch problem
authorHaibin Wang <wanghaibin.wang@huawei.com>
Thu, 10 Apr 2014 12:14:32 +0000 (13:14 +0100)
committerChristoffer Dall <christoffer.dall@linaro.org>
Mon, 28 Apr 2014 10:30:46 +0000 (03:30 -0700)
When dispatch SGI(mode == 0), that is the vcpu of VM should send
sgi to the cpu which the target_cpus list.
So, there must add the "break" to branch of case 0.

Cc: <stable@vger.kernel.org> # 3.10+
Signed-off-by: Haibin Wang <wanghaibin.wang@huawei.com>
Acked-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
virt/kvm/arm/vgic.c

index 47b29834a6b61def09f6340013cc9b2927c03cd9..7e8b44efb73907948e3e5f06428ed01e851710a5 100644 (file)
@@ -916,6 +916,7 @@ static void vgic_dispatch_sgi(struct kvm_vcpu *vcpu, u32 reg)
        case 0:
                if (!target_cpus)
                        return;
+               break;
 
        case 1:
                target_cpus = ((1 << nrcpus) - 1) & ~(1 << vcpu_id) & 0xff;