From: Avi Kivity <avi@redhat.com>
To: Mohammed Gamal <m.gamal005@gmail.com>
Cc: mtosatti@redhat.com, kvm@vger.kernel.org
Subject: Re: [RFC PATCH 0/3] Real mode interrupt injection
Date: Wed, 11 Aug 2010 07:15:34 -0400 [thread overview]
Message-ID: <4C628656.8060208@redhat.com> (raw)
In-Reply-To: <AANLkTi=nq+7hPw1XLksP+ocVoKHxBS9vUEiKmw-GF-8Q@mail.gmail.com>
On 08/10/2010 01:06 PM, Mohammed Gamal wrote:
>
> In the other instance the guest seems to jump to nowhere after
> successfully running the BIOS, the emulator then seems to emulate
> garbage. Here is the relevant part of the trace:
>
> qemu-system-x86-4327 [001] 169.394467: kvm_exit: reason
> EXCEPTION_NMI rip 0x7e1f
> qemu-system-x86-4327 [001] 169.394467: kvm_page_fault: address 4c
> error_code 9
Here, the guest tried to execute INT 13, but exited since the IDT was
paged out.
> qemu-system-x86-4327 [001] 169.394470: kvm_inj_virq: irq 19
vmx_complete_interrupts() recovered the interrupt (0x13 == 19) and is
reinjecting it
> qemu-system-x86-4327 [001] 169.394475: kvm_entry: vcpu 0
> qemu-system-x86-4327 [001] 169.394477: kvm_exit: reason
> EXCEPTION_NMI rip 0x7e1f
> qemu-system-x86-4327 [001] 169.394478: kvm_page_fault: address
> f7e1f error_code 1d
f7e1f seems to be in the middle of some instruction:
f7e03: 26 67 8b 28 addr32 mov %es:(%eax),%bp
f7e07: 66 0f b7 ed movzwl %bp,%ebp
f7e0b: 66 83 c1 0c add $0xc,%ecx
f7e0f: 66 89 c8 mov %ecx,%eax
f7e12: 66 c1 e8 04 shr $0x4,%eax
f7e16: 8e c0 mov %ax,%es
f7e18: 66 83 e1 0f and $0xf,%ecx
f7e1c: 26 67 66 8b 01 addr32 mov %es:(%ecx),%eax
f7e21: 67 66 89 44 24 14 addr32 mov %eax,0x14(%esp)
f7e27: 66 89 ee mov %ebp,%esi
f7e2a: 66 0f af f2 imul %edx,%esi
f7e2e: 66 01 c6 add %eax,%esi
f7e31: 8c d0 mov %ss,%ax
f7e33: 8e c0 mov %ax,%es
f7e35: 66 89 f2 mov %esi,%edx
f7e38: 66 c1 ea 04 shr $0x4,%edx
f7e3c: 66 83 e6 0f and $0xf,%esi
f7e40: 66 89 e9 mov %ebp,%ecx
f7e43: 67 66 8b 7c 24 18 addr32 mov 0x18(%esp),%edi
So, looks like the reinjection failed. Please add trace_printk()s so we
can see what values the emulator read from the IDT (and from what
address it read them).
--
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.
prev parent reply other threads:[~2010-08-11 11:15 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-08 19:24 [RFC PATCH 0/3] Real mode interrupt injection Mohammed Gamal
2010-08-08 19:24 ` [RFC PATCH 1/3] x86 emulator: Expose emulate_int_real() Mohammed Gamal
2010-08-08 19:24 ` [RFC PATCH 2/3] x86: Add inject_realmode_interrupt() wrapper Mohammed Gamal
2010-08-10 2:57 ` Avi Kivity
2010-08-08 19:24 ` [RFC PATCH 3/3] VMX: Emulated real mode interrupt injection Mohammed Gamal
2010-08-10 3:03 ` Avi Kivity
2010-08-10 17:13 ` Mohammed Gamal
2010-08-10 22:52 ` Avi Kivity
2010-08-10 2:52 ` [RFC PATCH 0/3] Real " Avi Kivity
2010-08-10 17:06 ` Mohammed Gamal
2010-08-10 23:02 ` Avi Kivity
2010-08-11 1:19 ` Mohammed Gamal
[not found] ` <AANLkTimmhvH2q7cCJZ+AV0OYhbvz=AZ_LLA3jU-nLdF1@mail.gmail.com>
2010-08-11 11:04 ` Avi Kivity
2010-08-11 11:20 ` Avi Kivity
2010-08-11 12:08 ` Avi Kivity
2010-08-11 23:22 ` Mohammed Gamal
2010-08-12 0:48 ` Avi Kivity
2010-08-12 1:07 ` Mohammed Gamal
2010-08-15 12:23 ` Avi Kivity
2010-08-15 12:30 ` Mohammed Gamal
2010-08-11 11:15 ` Avi Kivity [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=4C628656.8060208@redhat.com \
--to=avi@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=m.gamal005@gmail.com \
--cc=mtosatti@redhat.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.