From: Oliver Upton <oupton@kernel.org>
To: Marc Zyngier <maz@kernel.org>
Cc: Catalin Marinas <catalin.marinas@arm.com>,
Will Deacon <will@kernel.org>, Sven Peter <sven@kernel.org>,
Janne Grunau <j@jannau.net>, Thomas Gleixner <tglx@kernel.org>,
Peter Zijlstra <peterz@infradead.org>,
Ingo Molnar <mingo@redhat.com>,
Arnaldo Carvalho de Melo <acme@kernel.org>,
Namhyung Kim <namhyung@kernel.org>,
Fuad Tabba <fuad.tabba@linux.dev>,
Joey Gouly <joey.gouly@arm.com>,
Steffen Eiden <seiden@linux.ibm.com>,
Suzuki K Poulose <suzuki.poulose@arm.com>,
Zenghui Yu <yuzenghui@huawei.com>,
Mark Rutland <mark.rutland@arm.com>, Neal Gompa <neal@gompa.dev>,
Radu Rendec <radu@rendec.net>,
Alexander Shishkin <alexander.shishkin@linux.intel.com>,
Jiri Olsa <jolsa@kernel.org>, Ian Rogers <irogers@google.com>,
Adrian Hunter <adrian.hunter@intel.com>,
James Clark <james.clark@linaro.org>,
linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev,
linux-kernel@vger.kernel.org, asahi@lists.linux.dev,
linux-perf-users@vger.kernel.org
Subject: Re: [PATCH 1/4] KVM: arm64: Track IRQ and FIQ exceptions separately
Date: Wed, 2 Dec 2026 09:44:52 -0800 [thread overview]
Message-ID: <axBZFOJdHCKffgf8@kernel.org> (raw)
In-Reply-To: <86cxrjyfld.wl-maz@kernel.org>
On Wed, Dec 02, 2026 at 01:30:54PM +0000, Marc Zyngier wrote:
> On Tue, 01 Dec 2026 20:44:59 +0000,
> Oliver Upton <oupton@kernel.org> wrote:
>
> [...]
>
> > diff --git a/arch/arm64/kvm/hyp/entry.S b/arch/arm64/kvm/hyp/entry.S
> > index 9709905f21b5..7d38bae49d31 100644
> > --- a/arch/arm64/kvm/hyp/entry.S
> > +++ b/arch/arm64/kvm/hyp/entry.S
> > @@ -48,7 +48,13 @@ alternative_else_nop_endif
> > // synchronization event so that callers don't need ISBs for anything
> > // that would usually be synchronized by the ERET.
> > isb
> > +
> > + // Both a FIQ and IRQ could be pending. Arbitrarily give precedence
> > + // to reporting a pending FIQ.
> > mov x0, #ARM_EXCEPTION_IRQ
> > + mov x2, #ARM_EXCEPTION_FIQ
> > + tst x1, #ISR_EL1_F
> > + csel x0, x2, x0, ne
>
> I think this has the potential of going wrong on an NMI capable
> platform. Not that we support that yet, but it is around the corner.
> I also wonder if we should simply re-encode the exception types to
> better align with ISR_EL1. In any case, something like:
>
> orr x1, x1, x1, lsr #(ISR_EL1_FS_SHIFT - ISR_EL1_F_SHIFT)
> tst x1, #ISR_EL1_F
> csel x0, x2, x0, ne
>
> should do the trick.
Yep, works for me. I've got this applied locally, will include it in a
respin if that proves necessary.
Thanks,
Oliver
next prev parent reply other threads:[~2026-12-02 17:44 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-01 20:44 [PATCH 0/4] KVM: arm64: Fixes for guest-only PMU event overflows on Apple Silicon Oliver Upton
2026-12-01 20:44 ` [PATCH 1/4] KVM: arm64: Track IRQ and FIQ exceptions separately Oliver Upton
2026-12-02 13:30 ` Marc Zyngier
2026-12-02 17:44 ` Oliver Upton [this message]
2026-12-01 20:45 ` [PATCH 2/4] perf kvm stat: Add new 'ARM_EXCEPTION_FIQ' exception type Oliver Upton
2026-12-01 20:45 ` [PATCH 3/4] KVM: arm64: Let the irqchip provide a fixup for FIQs taken to EL2 Oliver Upton
2026-12-01 20:45 ` [PATCH 4/4] irqchip/apple-aic: Work around FIQ storms upon vPMU counter overflow Oliver Upton
2026-12-01 20:51 ` [PATCH 0/4] KVM: arm64: Fixes for guest-only PMU event overflows on Apple Silicon sashiko-bot
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=axBZFOJdHCKffgf8@kernel.org \
--to=oupton@kernel.org \
--cc=acme@kernel.org \
--cc=adrian.hunter@intel.com \
--cc=alexander.shishkin@linux.intel.com \
--cc=asahi@lists.linux.dev \
--cc=catalin.marinas@arm.com \
--cc=fuad.tabba@linux.dev \
--cc=irogers@google.com \
--cc=j@jannau.net \
--cc=james.clark@linaro.org \
--cc=joey.gouly@arm.com \
--cc=jolsa@kernel.org \
--cc=kvmarm@lists.linux.dev \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=maz@kernel.org \
--cc=mingo@redhat.com \
--cc=namhyung@kernel.org \
--cc=neal@gompa.dev \
--cc=peterz@infradead.org \
--cc=radu@rendec.net \
--cc=seiden@linux.ibm.com \
--cc=suzuki.poulose@arm.com \
--cc=sven@kernel.org \
--cc=tglx@kernel.org \
--cc=will@kernel.org \
--cc=yuzenghui@huawei.com \
/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