Kernel KVM virtualization development
 help / color / mirror / Atom feed
From: Sean Christopherson <seanjc@google.com>
To: Jim Mattson <jmattson@google.com>
Cc: sashiko-reviews@lists.linux.dev, kvm@vger.kernel.org
Subject: Re: [PATCH] KVM: x86: Disallow EFER.LMSLE when EferLmsleUnsupported is set in guest CPUID
Date: Tue, 22 Sep 2026 07:26:44 -0700	[thread overview]
Message-ID: <arKQJJJB8HMK0B1G@google.com> (raw)
In-Reply-To: <CALMp9eQboC6DTQfa3N58XCfOLf-qwJ2L7dC5vtqDerHG80eZLg@mail.gmail.com>

On Tue, Sep 22, 2026, Jim Mattson wrote:
> On Tue, Sep 22, 2026 at 6:57 AM Sean Christopherson <seanjc@google.com> wrote:
> > Gah, I hate the negative "feature" bits, I've gotten completely turned around
> > multiple times trying to sort through this.
> 
> Me too!
> 
> > IIUC, you're trying to "fix" setups where host CPUID.EFER_LMSLE_MBZ=0, but userspace
> > configured guest CPUID.EFER_LMSLE_MBZ=1?  If so, then Sashiko is right, it needs to
> > be declared with EMULATED_F().  I would even argue that technically this isn't a KVM
> > bug, because KVM won't advertise EFER_LMSLE_MBZ in KVM_GET_SUPPORTED_CPUID on such
> > hosts.
> 
> I'm trying to make it possible to run a Rome vCPU on Milan or later.
> 
> SInce this is a negative feature bit, it must be retained if the host
> reports it. That blocks running a Rome vCPU on Milan or later.
> However, a defeatured Rome (which reports LMSLE_MBZ as 1) can be run

So, a partially defeatured Rome?  Because it sounds like the CPU reports LMSLE_MBZ=1,
but then still allows setting EFER.LMSLE=1?

> on Milan and later.
> 
> It's the same feature-hiding we do all of the time—just inverted.

  reply	other threads:[~2026-09-22 14:26 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-18 15:45 [PATCH] KVM: x86: Disallow EFER.LMSLE when EferLmsleUnsupported is set in guest CPUID Jim Mattson
2026-09-18 15:56 ` Sean Christopherson
2026-09-18 16:01 ` sashiko-bot
2026-09-22 13:57   ` Sean Christopherson
2026-09-22 14:20     ` Jim Mattson
2026-09-22 14:26       ` Sean Christopherson [this message]
2026-09-22 14:34         ` Jim Mattson
2026-09-22 17:53           ` Sean Christopherson
2026-09-22 18:08             ` Jim Mattson
2026-09-22 18:34               ` Sean Christopherson

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=arKQJJJB8HMK0B1G@google.com \
    --to=seanjc@google.com \
    --cc=jmattson@google.com \
    --cc=kvm@vger.kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /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