From: eric.auger@linaro.org (Eric Auger)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v4 0/4] irqchip: GICv2/v3: Add support for irq_vcpu_affinity
Date: Thu, 27 Aug 2015 15:03:12 +0200 [thread overview]
Message-ID: <55DF0A90.9010407@linaro.org> (raw)
In-Reply-To: <1440604845-28229-1-git-send-email-marc.zyngier@arm.com>
Hi Marc,
I tested the series on Calxeda Midway with VFIO use case. Also reviewed
it again without finding anything new.
Tested-by: Eric Auger <eric.auger@linaro.org>
Reviewed-by: Eric Auger <eric.auger@linaro.org>
Best Regards
Eric
On 08/26/2015 06:00 PM, Marc Zyngier wrote:
> The GICv2 and GICv3 architectures allow an active physical interrupt
> to be forwarded to a guest, and the guest to indirectly perform the
> deactivation of the interrupt by performing an EOI on the virtual
> interrupt (see for example the GICv2 spec, 3.2.1).
>
> This allows some substantial performance improvement for level
> triggered interrupts that otherwise have to be masked/unmasked in
> VFIO, not to mention the required trap back to KVM when the guest
> performs an EOI.
>
> To enable this, the GICs need to be switched to a different EOImode,
> where a taken interrupt can be left "active" (which prevents the same
> interrupt from being taken again), while other interrupts are still
> being processed normally.
>
> We also use the new irq_set_vcpu_affinity hook that was introduced for
> Intel's "Posted Interrupts" to determine whether or not to perform the
> deactivation at EOI-time.
>
> As all of this only makes sense when the kernel can behave as a
> hypervisor, we only enable this mode on detecting that the kernel was
> actually booted in HYP mode, and that the GIC supports this feature.
>
> This series is a complete rework of a RFC I sent over a year ago:
>
> http://lists.infradead.org/pipermail/linux-arm-kernel/2014-June/266328.html
>
> Since then, a lot has been either merged (the irqchip_state) or reworked
> (my active-timer series: http://www.spinics.net/lists/kvm/msg118768.html),
> and this implements the last few bits for Eric Auger's series to
> finally make it into the kernel:
>
> https://lkml.org/lkml/2015/7/2/268
> https://lkml.org/lkml/2015/7/6/291
>
> With all these patches combined, physical interrupt routing from the
> kernel into a VM becomes possible.
>
> Note that the implementation makes use of the static_key mechanism,
> which is undergoing an extensive rework in 4.3. I intend to convert
> this code once both are in mainline.
>
> This has been tested on Juno (GICv2) and FastModel (GICv3). A branch
> is available at:
>
> git://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms.git irq/gic-irq-vcpu-affinity-v4
>
> * From v3:
> - Use separate irq_chip structures, leading to much nicer code (tglx)
> - Dropped Eric's Tested/Reviewed-by as there is significant changes
>
> * From v2:
> - Another small fix from Eric
> - Some commit message cleanups
>
> * From v1:
> - Fixes after review from Eric
> - Got rid of the cascaded GICv2 hack (it was broken anyway)
> - Folded the LPI deactivation patch (it makes more sense as part of
> the main one.
> - Some clarifying comments about the "deactivate on mask"
> - I haven't retained Eric's Reviewed/Tested-by, as the code as
> significantly changed on GICv2
>
> Marc Zyngier (4):
> irqchip: GICv3: Convert to EOImode == 1
> irqchip: GICv3: Don't deactivate interrupts forwarded to a guest
> irqchip: GIC: Convert to EOImode == 1
> irqchip: GIC: Don't deactivate interrupts forwarded to a guest
>
> drivers/irqchip/irq-gic-v3.c | 70 +++++++++++++++++++++--
> drivers/irqchip/irq-gic.c | 111 ++++++++++++++++++++++++++++++++++++-
> include/linux/irqchip/arm-gic-v3.h | 9 +++
> include/linux/irqchip/arm-gic.h | 4 ++
> 4 files changed, 188 insertions(+), 6 deletions(-)
>
next prev parent reply other threads:[~2015-08-27 13:03 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-08-26 16:00 [PATCH v4 0/4] irqchip: GICv2/v3: Add support for irq_vcpu_affinity Marc Zyngier
2015-08-26 16:00 ` [PATCH v4 1/4] irqchip: GICv3: Convert to EOImode == 1 Marc Zyngier
2015-08-26 16:00 ` [PATCH v4 2/4] irqchip: GICv3: Don't deactivate interrupts forwarded to a guest Marc Zyngier
2015-08-26 16:00 ` [PATCH v4 3/4] irqchip: GIC: Convert to EOImode == 1 Marc Zyngier
2015-09-09 19:23 ` Julien Grall
2015-09-10 9:54 ` Marc Zyngier
2015-09-10 10:55 ` Marc Zyngier
2015-09-10 16:23 ` Julien Grall
2015-09-10 16:30 ` Marc Zyngier
2015-09-10 16:30 ` Julien Grall
2015-09-11 10:54 ` Ian Campbell
2015-09-11 10:59 ` Julien Grall
2015-09-11 11:09 ` Marc Zyngier
2015-09-11 12:53 ` Julien Grall
2015-08-26 16:00 ` [PATCH v4 4/4] irqchip: GIC: Don't deactivate interrupts forwarded to a guest Marc Zyngier
2015-08-27 13:03 ` Eric Auger [this message]
2015-08-27 14:18 ` [PATCH v4 0/4] irqchip: GICv2/v3: Add support for irq_vcpu_affinity Marc Zyngier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=55DF0A90.9010407@linaro.org \
--to=eric.auger@linaro.org \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).