Re: [PATCH v2 1/4] KVM: arm64: Don't WARN on an unsupported TLBI OS from vEL1
From: Oliver Upton
Date: Mon Sep 28 2026 - 13:14:19 EST
Hi Fuad,
On Mon, Sep 28, 2026 at 07:46:40AM +0100, Fuad Tabba wrote:
> KVM hides TLBI OS from a guest whose ID registers don't advertise it by
> trapping the instructions: through the fine-grained traps on a CPU with
> FGT, and through HCR_EL2.TTLBOS on one with FEAT_EVT2. With FGT,
> triage_sysreg_trap() makes a trapped TLBI OS UNDEFINED. Without it, the
> instruction reaches handle_tlbi_el1(), which assumes an EL1 TLBI only
> traps from a guest at vEL2 and WARNs before checking whether the guest
> supports it. The guest still gets its UNDEF after the WARN. A VMM can
> trigger the WARN by hiding TLBI OS and having the guest execute one.
So the FGUs don't actually require any hardware support, they're just a
representation of our UNDEF emulation that can be applied even on
non-FGT. That's actually the way we had them wired before the whole
config.c rewrite.
Can you look into reinstating the FGUs?
Thanks,
Oliver