]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: arm/arm64: vgic: Only set underflow when actually out of LRs
authorChristoffer Dall <cdall@linaro.org>
Tue, 21 Mar 2017 20:16:12 +0000 (21:16 +0100)
committerChristoffer Dall <cdall@linaro.org>
Sun, 9 Apr 2017 14:45:32 +0000 (07:45 -0700)
commit0b3e21e29e0f8dd673a6615d824ac08a5cc4ec97
tree8928ee4f17bf82e88c1a7c0b49a4aa9cbff24f1d
parent5ccce36998f84cdd18a61da8b52da2c18e125919
KVM: arm/arm64: vgic: Only set underflow when actually out of LRs

We currently assume that all the interrupts in our AP list will be
queued to LRs, but that's not necessarily the case, because some of them
could have been migrated away to different VCPUs and only the VCPU
thread itself can remove interrupts from its AP list.

Therefore, slightly change the logic to only setting the underflow
interrupt when we actually run out of LRs.

As it turns out, this allows us to further simplify the handling in
vgic_sync_hwstate in later patches.

Acked-by: Marc Zyngier <marc.zyngier@arm.com>
Signed-off-by: Christoffer Dall <cdall@linaro.org>
virt/kvm/arm/vgic/vgic.c