Re: [PATCH v7 00/17] KVM: x86/pmu: Add support for AMD Host-Only/Guest-Only bits

From: Sean Christopherson

Date: Thu May 28 2026 - 14:10:29 EST


On Thu, May 28, 2026, Yosry Ahmed wrote:
> On Wed, May 27, 2026 at 7:28 PM Sean Christopherson <seanjc@xxxxxxxxxx> wrote:
> >
> > On Wed, May 27, 2026, Yosry Ahmed wrote:
> > > Jim Mattson (2):
> > > KVM: x86/pmu: Allow Host-Only/Guest-Only bits with nSVM and mediated
> > > PMU
> > > KVM: selftests: Add svm_pmu_host_guest_test for Host-Only/Guest-Only
> > > bits
> > >
> > > Yosry Ahmed (15):
> > > KVM: nSVM: Stop leaking single-stepping on VMRUN into L2
> > > KVM: nSVM: Bail early out of VMRUN emulation if advancing RIP fails
> > > KVM: nSVM: Unify RIP and PMU handling calls when emulating VMRUN
> > > KVM: nSVM: Move VMRUN instruction retirement after entering guest mode
> > > KVM: x86: Move enable_pmu/enable_mediated_pmu to pmu.h and pmu.c
> > > KVM: x86/pmu: Rename reprogram_counters() to clarify usage
> > > KVM: x86/pmu: Do a single atomic OR when reprogramming counters
> > > KVM: x86/pmu: Check mediated PMU counter enablement before event
> > > filters
> > > KVM: x86/pmu: Add support for KVM_X86_PMU_OP_OPTIONAL_RET0
> > > KVM: x86/pmu: Disable counters based on Host-Only/Guest-Only bits in
> > > SVM
> > > KVM: x86/pmu: Track mediated PMU counters with mode-specific enables
> > > KVM: x86/pmu: Reprogram Host/Guest-Only counters on nested transitions
> > > KVM: selftests: Refactor allocating guest stack into a helper
> > > KVM: selftests: Allocate a dedicated guest page for x86 L2 guest stack
> > > KVM: selftests: Drop L1-provided stacks for L2 guests on x86
> >
> > This all looks good. I'll get the KVM changes applied and pushed (assuming they
> > pass testing).
> >
> > For the selftests, I'm going to hold off on applying them until after the initial
> > pull requests for 7.2 are merged into Paolo's tree. The (AWESOME!!!) L2 stack
> > changes are going to cause conflict hell, and it's easy enough for me to carry
> > them out of tree for a few weeks.
> >
> > I'll send a refreshed version of the selftest once kvm-x86 has settled down for
> > 7.2, e.g. to account for the gpat test as well.
>
> So do you plan on getting it merged later in the 7.2 merge window or
> for 7.3? I think the former but I am not quite sure.

Ideally, later in the 7.2 merge window. Worst case scenario, super duper early
in kvm/next for 7.3, so that developers (and me) can build on the functionality.