From: Josh Triplett <josh@joshtriplett.org>
To: Alexander Graf <agraf@suse.de>
Cc: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] target-i386: GPF on invalid MSRs
Date: Fri, 27 May 2011 08:13:31 -0700 [thread overview]
Message-ID: <20110527151330.GA10016@leaf> (raw)
In-Reply-To: <59EA76FC-950D-4397-962C-338CBAE71E33@suse.de>
On Thu, May 26, 2011 at 11:12:12AM +0200, Alexander Graf wrote:
> On 26.05.2011, at 11:08, Josh Triplett wrote:
> > qemu currently returns 0 for rdmsr on invalid MSRs, and ignores wrmsr on
> > invalid MSRs. Real x86 processors GPF on invalid MSRs, which allows
> > software to detect unavailable MSRs. Emulate this behavior correctly in
> > qemu.
> >
> > Bug discovered via the BIOS Implementation Test Suite
> > <http://biosbits.org/>; fix tested the same way, for both 32-bit and
> > 64-bit x86.
>
> This would break a _lot_ of guests that work just fine today, as qemu doesn't handle all the necessary MSRs.
It also fixes guests that rely on the GPF to indicate the absence of an
MSR, and assume that the lack of GPF means the availability of that MSR.
Silently returning 0 for unknown MSRs means silent breakage.
What (buggy) guests expect to use random model-specific registers
without either handling GPFs or checking the CPU model first?
What MSRs do those guests expect that qemu doesn't currently implement?
If this represents a workaround for buggy guests, then may I add an
option to control this behavior?
- Josh Triplett
next prev parent reply other threads:[~2011-05-27 15:13 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-26 9:08 [Qemu-devel] [PATCH] target-i386: GPF on invalid MSRs Josh Triplett
2011-05-26 9:12 ` Alexander Graf
2011-05-27 15:13 ` Josh Triplett [this message]
2011-05-27 15:16 ` Alexander Graf
2011-05-27 15:46 ` Josh Triplett
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=20110527151330.GA10016@leaf \
--to=josh@joshtriplett.org \
--cc=agraf@suse.de \
--cc=qemu-devel@nongnu.org \
/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;
as well as URLs for NNTP newsgroup(s).