KVM: arm64: Reduce occurence of GICv4 doorbells on non-oversubscribed systems
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest2 patches 3 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | KVM: vgic-v4: Track the number of VLPIs per vcpuinclude/ virt/ virt/ +1 more | +8 | 1 reply | |
| 2/2 | KVM: arm64: Opportunistically turn off WFI trapping when using direct LPI injectionarch/ arch/ virt/ | +11 | 1 reply |
Reviews trailers per patch
All 2 patches have a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Christoffer Dall | Zenghui Yu |
|---|---|---|
| Series | R-b | |
| 1/2 | R-b | |
| 2/2 | R-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/2] KVM: arm64: Reduce occurence of GICv4 doorbells on non-oversubscribed systems
As I was cleaning up some of the GICv4 code to make way for GICv4.1 it occured to me that we could drastically reduce the impact of the GICv4 doorbells on systems that are not oversubscribed (each vcpu "owns" a physical CPU).
The technique borrows its logic from the way we disable WFE trapping when a vcpu is the only process on the CPU run-queue. If this vcpu is the target of VLPIs, it is then beneficial not to trap blocking WFIs and to leave the vcpu waiting for interrupts in guest state.
All we need to do here is to track whether VLPIs are associated to a vcpu (which is easily done by using a counter that we update on MAPI, DISCARD and MOVI).
It has been *very lightly* tested on a D05, and behaved pretty well in my limited test cases (I get almost no doorbell at all in the non oversubscribed case, and the usual hailstorm as soon as there is oversubscription). I'd welcome some testing on more current HW.
Marc Zyngier (2):
KVM: vgic-v4: Track the number of VLPIs per vcpu
KVM: arm64: Opportunistically turn off WFI trapping when using direct
LPI injection
arch/arm/include/asm/kvm_emulate.h | 4 ++-- arch/arm64/include/asm/kvm_emulate.h | 9 +++++++-- include/linux/irqchip/arm-gic-v4.h | 2 ++ virt/kvm/arm/arm.c | 4 ++-- virt/kvm/arm/vgic/vgic-init.c | 1 + virt/kvm/arm/vgic/vgic-its.c | 3 +++ virt/kvm/arm/vgic/vgic-v4.c | 2 ++ 7 files changed, 19 insertions(+), 6 deletions(-)
Signature · 1 line
2.20.1