From: Peter Maydell <peter.maydell@linaro.org>
To: qemu-arm@nongnu.org, qemu-devel@nongnu.org
Cc: "Shashi Mallela" <shashi.mallela@linaro.org>,
"Alex Bennée" <alex.bennee@linaro.org>
Subject: [PATCH 06/14] hw/intc/arm_gicv3: Honour GICD_CTLR.EnableGrp1NS for LPIs
Date: Sat, 22 Jan 2022 18:24:36 +0000 [thread overview]
Message-ID: <20220122182444.724087-7-peter.maydell@linaro.org> (raw)
In-Reply-To: <20220122182444.724087-1-peter.maydell@linaro.org>
The GICD_CTLR distributor register has enable bits which control
whether the different interrupt groups (Group 0, Non-secure Group 1
and Secure Group 1) are forwarded to the CPU. We get this right for
traditional interrupts, but forgot to account for it when adding
LPIs. LPIs are always Group 1 NS and if the EnableGrp1NS bit is not
set we must not forward them to the CPU.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
---
hw/intc/arm_gicv3.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/hw/intc/arm_gicv3.c b/hw/intc/arm_gicv3.c
index 715df5421dd..6d3c8ee231c 100644
--- a/hw/intc/arm_gicv3.c
+++ b/hw/intc/arm_gicv3.c
@@ -166,6 +166,7 @@ static void gicv3_redist_update_noirqset(GICv3CPUState *cs)
}
if ((cs->gicr_ctlr & GICR_CTLR_ENABLE_LPIS) && cs->gic->lpi_enable &&
+ (cs->gic->gicd_ctlr & GICD_CTLR_EN_GRP1NS) &&
(cs->hpplpi.prio != 0xff)) {
if (irqbetter(cs, cs->hpplpi.irq, cs->hpplpi.prio)) {
cs->hppi.irq = cs->hpplpi.irq;
--
2.25.1
next prev parent reply other threads:[~2022-01-22 19:03 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-01-22 18:24 [PATCH 00/14] arm_gicv3_its: Implement MOVI and MOVALL commands Peter Maydell
2022-01-22 18:24 ` [PATCH 01/14] target/arm: Log CPU index in 'Taking exception' log Peter Maydell
2022-01-23 22:00 ` Philippe Mathieu-Daudé via
2022-01-28 3:09 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 02/14] hw/intc/arm_gicv3_its: Add tracepoints Peter Maydell
2022-01-23 22:01 ` Philippe Mathieu-Daudé via
2022-01-28 3:10 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 03/14] hw/intc/arm_gicv3: Initialise dma_as in GIC, not ITS Peter Maydell
2022-01-28 3:12 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 04/14] hw/intc/arm_gicv3_its: Don't clear GITS_CREADR when GITS_CTLR.ENABLED is set Peter Maydell
2022-01-28 3:12 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 05/14] hw/intc/arm_gicv3_its: Don't clear GITS_CWRITER on writes to GITS_CBASER Peter Maydell
2022-01-28 3:13 ` Richard Henderson
2022-01-22 18:24 ` Peter Maydell [this message]
2022-01-28 3:15 ` [PATCH 06/14] hw/intc/arm_gicv3: Honour GICD_CTLR.EnableGrp1NS for LPIs Richard Henderson
2022-01-22 18:24 ` [PATCH 07/14] hw/intc/arm_gicv3_its: Sort ITS command list into numeric order Peter Maydell
2022-01-23 22:02 ` Philippe Mathieu-Daudé via
2022-01-28 3:15 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 08/14] hw/intc/arm_gicv3_redist: Remove unnecessary zero checks Peter Maydell
2022-01-28 3:17 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 09/14] hw/intc/arm_gicv3: Set GICR_CTLR.CES if LPIs are supported Peter Maydell
2022-01-28 3:19 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 10/14] hw/intc/arm_gicv3_its: Provide read accessor for translation_ops Peter Maydell
2022-01-23 22:04 ` Philippe Mathieu-Daudé via
2022-01-28 3:27 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 11/14] hw/intc/arm_gicv3_its: Make GITS_BASER<n> RAZ/WI for unimplemented registers Peter Maydell
2022-01-28 3:31 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 12/14] hw/intc/arm_gicv3_its: Check table bounds against correct limit Peter Maydell
2022-01-28 3:32 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 13/14] hw/intc/arm_gicv3_its: Implement MOVALL Peter Maydell
2022-01-28 3:37 ` Richard Henderson
2022-01-22 18:24 ` [PATCH 14/14] hw/intc/arm_gicv3_its: Implement MOVI Peter Maydell
2022-01-28 3:38 ` Richard Henderson
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=20220122182444.724087-7-peter.maydell@linaro.org \
--to=peter.maydell@linaro.org \
--cc=alex.bennee@linaro.org \
--cc=qemu-arm@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=shashi.mallela@linaro.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).