]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: PPC: Book3S HV: XIVE: Resend re-routed interrupts on CPU priority change
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 10 May 2018 03:06:42 +0000 (13:06 +1000)
committerPaul Mackerras <paulus@ozlabs.org>
Thu, 17 May 2018 05:17:06 +0000 (15:17 +1000)
commit64d7b6e03e1f75e7286bdbe8e8ab470659078f25
tree7582e7317a7947d1ea5eeddfd39538c30919877a
parent028f2cf2b616fb2383cd2f0d789e3d306c37221e
KVM: PPC: Book3S HV: XIVE: Resend re-routed interrupts on CPU priority change

When a vcpu priority (CPPR) is set to a lower value (masking more
interrupts), we stop processing interrupts already in the queue
for the priorities that have now been masked.

If those interrupts were previously re-routed to a different
CPU, they might still be stuck until the older one that has
them in its queue processes them. In the case of guest CPU
unplug, that can be never.

To address that without creating additional overhead for
the normal interrupt processing path, this changes H_CPPR
handling so that when such a priority change occurs, we
scan the interrupt queue for that vCPU, and for any
interrupt in there that has been re-routed, we replace it
with a dummy and force a re-trigger.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Tested-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Paul Mackerras <paulus@ozlabs.org>
arch/powerpc/kvm/book3s_xive_template.c