Re: [Patch v4 3/4] x86/sev: Add guest support for Enhanced SMT Protection

From: Sean Christopherson

Date: Fri Nov 13 2026 - 12:17:31 EST


On Thu, Nov 12, 2026, Borislav Petkov wrote:
> On Mon, Nov 09, 2026 at 08:35:13PM +0000, Pratik R. Sampat wrote:
> > @@ -849,6 +850,18 @@ static int wakeup_cpu_via_vmgexit(u32 apic_id, unsigned long start_ip, unsigned
> > vmsa->vmpl = snp_vmpl;
> > vmsa->sev_features = sev_status >> 2;
> >
> > + if (sev_status & MSR_AMD64_SEV_SNP_ENABLED &&
> > + (sev_status & MSR_AMD64_SNP_ESMT_PROT)) {
> > + vmsa->vcpu_id = apic_id;
> > + /*
> > + * The mask fully set puts every vCPU in one group, so any two
> > + * of them may be co-resident. A legal ESMTP sibling must
> > + * also match on ASID, so the sibling of a vCPU in guest mode is
> > + * always either another vCPU of this same guest or idle.
> > + */
>
> This comment doesn't belong here.
>
> In any case, this set touches multiple trees so I'm open to suggestions from
> KVM folks how we should do the patch merging tetris eventually.

Post and merge the guest patches separately, and put any architectural collateral
need for the guest code in those patches. This is not high on my todo list, i.e.
the KVM patches can come later.