From: Paolo Bonzini <pbonzini@redhat.com>
To: Sean Christopherson <sean.j.christopherson@intel.com>
Cc: Like Xu <like.xu@linux.intel.com>,
kvm@vger.kernel.org, Wanpeng Li <wanpengli@tencent.com>,
Jim Mattson <jmattson@google.com>,
Vitaly Kuznetsov <vkuznets@redhat.com>,
Joerg Roedel <joro@8bytes.org>,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH] KVM/x86: pmu: Fix #GP condition check for RDPMC emulation
Date: Wed, 8 Jul 2020 17:54:41 +0200 [thread overview]
Message-ID: <face99cd-f19d-afb3-8f5f-ac5206ba39b4@redhat.com> (raw)
In-Reply-To: <20200708154520.GB22737@linux.intel.com>
On 08/07/20 17:45, Sean Christopherson wrote:
> On Wed, Jul 08, 2020 at 05:31:14PM +0200, Paolo Bonzini wrote:
>> The order follows the SDM. I'm tempted to remove the CR0 check
>> altogether, since non-protected-mode always runs at CPL0 AFAIK, but let's
>> keep it close to what the manual says.
>
> Heh, it wouldn't surprise me in the least if there's a way to get the SS
> arbyte to hold a non-zero DPL in real mode :-).
I'm not sure if SMM lets you set non-zero SS.DPL in real mode. It's one
of the few things that are checked with unrestricted guest mode so
there's hope; on the other hand I know for sure that in the past RSM
could get you to VM86 mode with CPL=0, while in VMX it causes vmentry to
fail.
It would be an interesting testcase to write for KVM, to see if you get
a vmentry failure after you set the hidden AR bytes that way and RSM...
Paolo
prev parent reply other threads:[~2020-07-08 15:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-08 7:44 Like Xu
2020-07-08 15:18 ` Sean Christopherson
2020-07-08 15:31 ` Paolo Bonzini
2020-07-08 15:45 ` Sean Christopherson
2020-07-08 15:54 ` Paolo Bonzini [this message]
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=face99cd-f19d-afb3-8f5f-ac5206ba39b4@redhat.com \
--to=pbonzini@redhat.com \
--cc=jmattson@google.com \
--cc=joro@8bytes.org \
--cc=kvm@vger.kernel.org \
--cc=like.xu@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=sean.j.christopherson@intel.com \
--cc=vkuznets@redhat.com \
--cc=wanpengli@tencent.com \
/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
all inboxes | Powered by JetHome®