]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: arm64: timer: Add support for SW-based deactivation
authorMarc Zyngier <maz@kernel.org>
Mon, 15 Mar 2021 14:21:21 +0000 (14:21 +0000)
committerMarc Zyngier <maz@kernel.org>
Tue, 1 Jun 2021 09:46:00 +0000 (10:46 +0100)
commitfa4184536c07c9d0f361bb0e25f2d2aa4b4574e7
tree3621fb6da192b5f8e8734b15765f0dd17605a548
parent995bb9bbd5c63b54e0f623ccfced7dc7042c68d8
KVM: arm64: timer: Add support for SW-based deactivation

In order to deal with the lack of active state, we need to use
the mask/unmask primitives (after all, the active state is just an
additional mask on top of the normal one).

To avoid adding a bunch of ugly conditionals in the timer and vgic
code, let's use a timer-specific irqdomain to deal with the state
conversion. Yes, this is an unexpected use of irqdomains, but
there is no reason not to be just as creative as the designers
of the HW...

This involves overloading the vcpu_affinity, set_irqchip_state
and eoi callbacks so that the rest of the KVM code can continue
ignoring the oddities of the underlying platform.

Signed-off-by: Marc Zyngier <maz@kernel.org>
arch/arm64/kvm/arch_timer.c