public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: "Serge E. Hallyn" <serge@hallyn.com>
To: KVM mailing list <kvm@vger.kernel.org>
Subject: buggy emulate_int_real
Date: Fri, 8 Apr 2011 16:09:01 -0500	[thread overview]
Message-ID: <20110408210900.GA26787@hallyn.com> (raw)

Hi,

at https://bugs.launchpad.net/ubuntu/+source/qemu-kvm/+bug/747090, it was
found that emulate_int_real() sometimes pushes the wrong eip when doing a
int.  Whereas with non-kvm qemu we push the next instruction after the
int, with kvm we push the addr of the instruction itself.

I thought it'd be simple to fix (bump the value being pushed :), but my
attempts at that have failed.  Well, the right value seemed to get pushed,
but kvm started to act rather funky.  So I just removed commits

a92601bb707f6f49fd5563ef3d09928e70cc222e
    KVM: VMX: Emulated real mode interrupt injection

63995653ade16deacaea5b49ceaf6376314593ac
    KVM: Add kvm_inject_realmode_interrupt() wrapper

6e154e56b4d7a6a28c54f0984e13d3f8defc4755
    KVM: x86 emulator: Add into, int, and int3 instructions (opcodes 0xcc-0xce)

and now it behaves as I'd expect.  There were a few commits tweaking these
functions, and I have not checked whether reverting some of those helps.

Anyone happen to know what exactly is going on?

thanks,
-serge

             reply	other threads:[~2011-04-08 21:09 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-08 21:09 Serge E. Hallyn [this message]
2011-04-10  8:30 ` buggy emulate_int_real Avi Kivity
2011-04-12  7:53   ` Serge E. Hallyn
2011-04-12  8:02     ` Avi Kivity
2011-04-12 13:57       ` Serge E. Hallyn
2011-04-12 14:14         ` Avi Kivity
2011-04-12 14:12       ` Serge E. Hallyn
2011-04-12 14:16         ` Avi Kivity
2011-04-12 15:42           ` Jan Kiszka
2011-04-12 18:31             ` Serge E. Hallyn
2011-04-12 20:51               ` Jan Kiszka
2011-04-12 21:25                 ` Serge E. Hallyn
2011-04-12 22:39                   ` Serge E. Hallyn
2011-04-12 23:31                     ` Jan Kiszka
2011-04-13 13:24                       ` Serge E. Hallyn
2011-04-13 13:29                         ` Avi Kivity
2011-04-13 13:52                           ` Serge E. Hallyn

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=20110408210900.GA26787@hallyn.com \
    --to=serge@hallyn.com \
    --cc=kvm@vger.kernel.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