Re: [PATCH v4 3/6] KVM: arm64: nv: Add nested revmap broken tracepoint

From: Wei-Lin Chang

Date: Thu Jul 16 2026 - 12:31:55 EST


On Thu, Jul 16, 2026 at 09:56:33AM +0100, Marc Zyngier wrote:
> On Thu, 16 Jul 2026 07:45:05 +0100,
> Oliver Upton <oupton@xxxxxxxxxx> wrote:
> >
> > Hi Wei-Lin,
> >
> > On Tue, Jul 14, 2026 at 12:59:22PM +0100, Wei-Lin Chang wrote:
> > > Add a tracepoint to track when a nested reverse map becomes broken. This
> > > makes it easier to detect NV performance degradation caused by full
> > > shadow stage-2 unmaps.
> > >
> > > Signed-off-by: Wei-Lin Chang <weilin.chang@xxxxxxx>
> >
> > I'm not too excited about making a tracepoint out of this, especially
> > since a 'broken' reverse map is more of a KVM implementation detail
> > (that could change) than anything else.
> >
> > BPF is quite popular at this point, do you think it's reasonable to
> > instead expect the curious KVM developer to attach a kprobe and inspect
> > the state of the nested MMU?
>
> I was the one asking for a way to report this stuff. I'd be completely
> fine with BPF as long as we give the recipe for this so that people
> can readily look at this.

Cool, I'll drop the tracepoint in the next iteration.

>
> Even better, find a way not to have a broken rmap the first place ;-).

One possible way is to not do the shadow stage-2 map if maple tree store
fails, please see the response for patch 2 for details!

Thanks,
Wei-Lin Chang

>
> Thanks,
>
> M.
>
> --
> Without deviation from the norm, progress is not possible.