OSDN Git Service

irqchip/gic-v4.1: Add support for VPENDBASER's Dirty+Valid signaling
authorMarc Zyngier <maz@kernel.org>
Fri, 10 Apr 2020 10:13:26 +0000 (11:13 +0100)
committerMarc Zyngier <maz@kernel.org>
Thu, 16 Apr 2020 09:28:12 +0000 (10:28 +0100)
commit96806229ca033f85310bc5c203410189f8a1d2ee
tree3efd53c7dbafa557de279447592109fccd9fe5ac
parent8f3d9f354286745c751374f5f1fcafee6b3f3136
irqchip/gic-v4.1: Add support for VPENDBASER's Dirty+Valid signaling

When a vPE is made resident, the GIC starts parsing the virtual pending
table to deliver pending interrupts. This takes place asynchronously,
and can at times take a long while. Long enough that the vcpu enters
the guest and hits WFI before any interrupt has been signaled yet.
The vcpu then exits, blocks, and now gets a doorbell. Rince, repeat.

In order to avoid the above, a (optional on GICv4, mandatory on v4.1)
feature allows the GIC to feedback to the hypervisor whether it is
done parsing the VPT by clearing the GICR_VPENDBASER.Dirty bit.
The hypervisor can then wait until the GIC is ready before actually
running the vPE.

Plug the detection code as well as polling on vPE schedule. While
at it, tidy-up the kernel message that displays the GICv4 optional
features.

Reviewed-by: Zenghui Yu <yuzenghui@huawei.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
drivers/irqchip/irq-gic-v3-its.c
drivers/irqchip/irq-gic-v3.c
include/linux/irqchip/arm-gic-v3.h