Re: [RFC PATCH 0/3] Real mode interrupt injection

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 8/10/10, Avi Kivity <avi@xxxxxxxxxx> wrote:
>   On 08/08/2010 03:24 PM, Mohammed Gamal wrote:
>> This patch introduces real mode interrupt injection for VMX.
>> It currently invokes the x86 emulator to emulate interrupts
>> instead of manually setting VMX controls.
>>
>> Needless to say, this is not meant for merging in its current state.
>> The emulator still needs some more work to get this completely
>> operational.
>
> Well, what happens when you run with it?
The guest fails at two instances. First it sometimes encounters a
group 7 instruction (0x0f 0x00), which the emulator doesn't emulate.
Here is the relevant part of the trace:

qemu-system-x86-4321  [001]   150.002191: kvm_entry: vcpu 0
 qemu-system-x86-4321  [001]   150.002196: kvm_exit: reason
IO_INSTRUCTION rip 0x3
 qemu-system-x86-4321  [001]   150.002197: kvm_pio: pio_read at 0x70
size 1 count 1
 qemu-system-x86-4321  [001]   150.002205: kvm_entry: vcpu 0
 qemu-system-x86-4321  [001]   150.002210: kvm_exit: reason
IO_INSTRUCTION rip 0x5
 qemu-system-x86-4321  [001]   150.002213: kvm_emulate_insn: f0000:5:
e4 71 (real)
 qemu-system-x86-4321  [001]   150.002215: kvm_pio: pio_write at 0x71
size 1 count 1
 qemu-system-x86-4321  [001]   150.002223: kvm_entry: vcpu 0
 qemu-system-x86-4321  [001]   150.002228: kvm_exit: reason
EXCEPTION_NMI rip 0x18
 qemu-system-x86-4321  [001]   150.002229: kvm_page_fault: address
ffff error_code f
 qemu-system-x86-4321  [001]   150.002270: kvm_entry: vcpu 0
 qemu-system-x86-4321  [001]   150.002276: kvm_exit: reason
EXCEPTION_NMI rip 0x1a
 qemu-system-x86-4321  [001]   150.002277: kvm_page_fault: address
d4dc error_code f
 qemu-system-x86-4321  [001]   150.002284: kvm_entry: vcpu 0
 qemu-system-x86-4321  [001]   150.002289: kvm_exit: reason
EXCEPTION_NMI rip 0x1d
 qemu-system-x86-4321  [001]   150.002292: kvm_emulate_insn: f0000:1d:
0f 00 (real)
 qemu-system-x86-4321  [001]   150.002294: kvm_inj_exception: #UD (0x0)
 qemu-system-x86-4321  [001]   150.002296: kvm_entry: vcpu 0
 qemu-system-x86-4321  [001]   150.002301: kvm_exit: reason
EXCEPTION_NMI rip 0x1d
 qemu-system-x86-4321  [001]   150.002302: kvm_page_fault: address 18
error_code 9
 qemu-system-x86-4321  [001]   150.002306: kvm_inj_virq: irq 6
 qemu-system-x86-4321  [001]   150.002311: kvm_entry: vcpu 0
 qemu-system-x86-4321  [001]   150.002315: kvm_exit: reason
EXCEPTION_NMI rip 0x1d
 qemu-system-x86-4321  [001]   150.002318: kvm_emulate_insn: f0000:1d:
0f 00 (real)

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
 qemu-system-x86-4327  [001]   169.394470: kvm_inj_virq: irq 19
 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
 qemu-system-x86-4327  [001]   169.394480: kvm_entry: vcpu 0
 qemu-system-x86-4327  [001]   169.394482: kvm_exit: reason
EXCEPTION_NMI rip 0x7e4d
 qemu-system-x86-4327  [001]   169.394482: kvm_page_fault: address
38e0 error_code f
 qemu-system-x86-4327  [001]   169.394496: kvm_entry: vcpu 0
 qemu-system-x86-4327  [001]   169.394498: kvm_exit: reason
EXCEPTION_NMI rip 0x8028
 qemu-system-x86-4327  [001]   169.394499: kvm_page_fault: address
f8028 error_code 1d
 qemu-system-x86-4327  [001]   169.394500: kvm_entry: vcpu 0
 qemu-system-x86-4327  [001]   169.394502: kvm_exit: reason
EXCEPTION_NMI rip 0x8034
 qemu-system-x86-4327  [001]   169.394505: kvm_emulate_insn:
f0000:8034: 66 c3 (real)
 qemu-system-x86-4327  [001]   169.394509: kvm_entry: vcpu 0
 qemu-system-x86-4327  [001]   169.394511: kvm_exit: reason
EXCEPTION_NMI rip 0x44bf8
 qemu-system-x86-4327  [001]   169.394516: kvm_emulate_insn:
f0000:44bf8: 00 00 (real)
 qemu-system-x86-4327  [001]   169.394519: kvm_entry: vcpu 0
 qemu-system-x86-4327  [001]   169.394521: kvm_exit: reason
EXCEPTION_NMI rip 0x44bfa
 qemu-system-x86-4327  [001]   169.394522: kvm_emulate_insn:
f0000:44bfa: 00 00 (real)
 qemu-system-x86-4327  [001]   169.394523: kvm_entry: vcpu 0
 qemu-system-x86-4327  [001]   169.394525: kvm_exit: reason
EXCEPTION_NMI rip 0x44bfc
 qemu-system-x86-4327  [001]   169.394526: kvm_emulate_insn:
f0000:44bfc: 00 00 (real)
 qemu-system-x86-4327  [001]   169.394527: kvm_entry: vcpu 0
 qemu-system-x86-4327  [001]   169.394529: kvm_exit: reason
EXCEPTION_NMI rip 0x44bfe
 qemu-system-x86-4327  [001]   169.394530: kvm_emulate_insn:
f0000:44bfe: 00 00 (real)
 qemu-system-x86-4327  [001]   169.394531: kvm_entry: vcpu 0
 qemu-system-x86-4327  [001]   169.394533: kvm_exit: reason
EXCEPTION_NMI rip 0x44c00
 qemu-system-x86-4327  [001]   169.394534: kvm_emulate_insn:
f0000:44c00: 00 00 (real)

I am not sure if this is correct behaviour at all.

Regards,
Mohammed
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux