* Out-of-box kvm-61 driver crash, first kvm problem ever, boo hoo...
@ 2008-02-20 7:45 duck
2008-02-20 9:24 ` Avi Kivity
0 siblings, 1 reply; 3+ messages in thread
From: duck @ 2008-02-20 7:45 UTC (permalink / raw)
To: kvm-devel
Just tried kvm-61. Ran up an existing, well-used, VM image. kvm-intel
crashed instantly. First KVM problem ever in several months of use.
(Haven't told the VMWare-huggers at work yet. They tend towards
superciliousness in respect of open source virtualisation solutions.)
Standardish Slackware 12.0 (kernel 2.6.21.5) with all offical patches
(except for the kernel, which was patched by me by hand -- one line change
-- against the recent 'vmsplice' thingy).
Went back over recent KVM releases, using default ./configure;make;make
install.
kvm-59, out of box, built by me: all good.
kvm-60, out of box, built by me: all good.
kvm-61, out of box, built by me: BANG, see dmesg output below.
I also tried kvm-61 code but with the kernel drivers from kvm-60: all good.
kvm-60 with the kernel drivers from kvm-61: BANG, see dmesg output below.
Command line to start kvm was this:
$ qemu-system-x86_64 -snapshot -m 512 myvmfile.qc2
As you will see below I also have kqemu loaded. This is not a mistake :-) I
use QEMU+KQEMU when I need to do Windbg kernel debugging or to use hardware
breakpoints in userland. (The former nearly works but doesn't actually, the
latter doesn't work at all, when using QEMU/KVM.) I use QEMU/KVM when I
want to do normal stuff. (Much faster.)
Just in case, I did the tests without kqemu loaded. Same results. Oh, and I
have some proprietary ATI stuff in there, as you will see. Sorry about
that. I need that driver so I kept it loaded in all my tests.
(Apologies. My MUA will wrap lines atrociously. Check my mail headers for
MUA identity. Can't bear to say it out loud. Read and weep.)
Am I doing something wrong?
Is there a way around this?
Currently staying on kvm59 which suits me fine. Just thought I'd sent this
in, in case.
---cut here---
Linux version 2.6.21.5-smp (root@duo) (gcc version 4.1.2) #2 SMP Sat Feb 16
22:52:45 EST 2008
[. . .]
e1000: eth0: e1000_watchdog: NIC Link is Up 100 Mbps Full Duplex, Flow
Control: RX/TX
e1000: eth0: e1000_watchdog: 10/100 speed: disabling TSO
kvm: emulating preempt notifiers; do not benchmark on this machine
loaded kvm module (kvm-59)
QEMU Accelerator Module version 1.3.0, Copyright (c) 2005-2007 Fabrice
Bellard
KQEMU installed, max_locked_mem=1036868kB.
ACPI: PCI Interrupt 0000:01:00.0[A] -> GSI 16 (level, low) -> IRQ 16
[fglrx] total GART = 130023424
[fglrx] free GART = 114032640
[fglrx] max single GART = 114032640
[fglrx] total LFB = 134086656
[fglrx] free LFB = 110088192
[fglrx] max single LFB = 110088192
[fglrx] total Inv = 0
[fglrx] free Inv = 0
[fglrx] max single Inv = 0
[fglrx] total TIM = 0
kvm: emulating preempt notifiers; do not benchmark on this machine
loaded kvm module (kvm-59)
kvm: emulating preempt notifiers; do not benchmark on this machine
loaded kvm module (kvm-59)
kvm: emulating exchange as write
kvm: emulating preempt notifiers; do not benchmark on this machine
loaded kvm module (kvm-60)
kvm: emulating exchange as write
kvm: emulating preempt notifiers; do not benchmark on this machine
loaded kvm module (kvm-60)
kvm: emulating preempt notifiers; do not benchmark on this machine
loaded kvm module (kvm-61)
BUG: unable to handle kernel NULL pointer dereference at virtual address
00000008
printing eip:
f8b8dcd2
*pde = 00000000
Oops: 0002 [#1]
SMP
Modules linked in: kvm_intel kvm kqemu snd_seq_dummy snd_seq_oss
snd_seq_midi_event snd_seq snd_seq_device snd_pcm_oss snd_mixer_oss
capability commoncap lp usbhid parport_pc parport pcspkr psmouse pcmcia
fglrx(P) e1000 sdhci mmc_core tifm_7xx1 tifm_core yenta_socket
rsrc_nonstatic ohci1394 ieee1394 intel_agp agpgart i2c_i801 ata_generic
pcmcia_core evdev ehci_hcd serio_raw sg i2c_core snd_hda_intel
snd_hda_codec snd_pcm snd_timer iTCO_wdt snd uhci_hcd iTCO_vendor_support
soundcore snd_page_alloc shpchp ext3 jbd mbcache
CPU: 0
EIP: 0060:[<f8b8dcd2>] Tainted: P VLI
EFLAGS: 00010246 (2.6.21.5-smp #2)
EIP is at vmx_set_efer+0xa2/0xb0 [kvm_intel]
eax: 00000000 ebx: 00000000 ecx: 00004012 edx: 00004012
esi: 00000000 edi: f4830020 ebp: 00000000 esp: f4a63ed4
ds: 007b es: 007b fs: 00d8 gs: 0033 ss: 0068
Process qemu-system-x86 (pid: 6824, ti=f4a62000 task=f7884a30
task.ti=f4a62000)
Stack: f4830020 f4830020 f4ae8000 00000000 f8b8fad3 f8bb4f6d f4830020
0000ae41
f4830020 0000ae41 f8ba6309 f8ba6854 0000ae41 f4830020 f8ba5111
00000004
f4a79a5c f8bb2715 f4a63f54 f4a63f58 f4a63f5c 08194fa8 f7baddf4
f79a5200
Call Trace:
[<f8b8fad3>] vmx_vcpu_reset+0x293/0x3c0 [kvm_intel]
[<f8bb4f6d>] preempt_notifier_register+0x1d/0x8e [kvm]
[<f8ba6309>] kvm_arch_vcpu_reset+0x9/0x10 [kvm]
[<f8ba6854>] kvm_arch_vcpu_setup+0x14/0x60 [kvm]
[<f8ba5111>] kvm_vm_ioctl+0x101/0x1b0 [kvm]
[<f8bb2715>] kvm_anon_inode_getfd+0x115/0x160 [kvm]
[<f8ba462c>] kvm_dev_ioctl+0x14c/0x160 [kvm]
[<f8ba5010>] kvm_vm_ioctl+0x0/0x1b0 [kvm]
[<c0171d0b>] do_ioctl+0x2b/0x90
[<c0171dcc>] vfs_ioctl+0x5c/0x2a0
[<c0172082>] sys_ioctl+0x72/0x90
[<c0102ae8>] syscall_call+0x7/0xb
=======================
Code: ff ff 8d b4 26 00 00 00 00 b8 12 40 00 00 e8 26 f4 ff ff 25 ff fd ff
ff 89 c2 b8 12 40 00 00 e8 05 fd ff ff 89 d8 25 ff fe ff ff <89> 45 08 89
75 0c eb b6 8d b6 00 00 00 00 53 84 c9 8b 5c 24 08
EIP: [<f8b8dcd2>] vmx_set_efer+0xa2/0xb0 [kvm_intel] SS:ESP 0068:f4a63ed4
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Out-of-box kvm-61 driver crash, first kvm problem ever, boo hoo...
2008-02-20 7:45 Out-of-box kvm-61 driver crash, first kvm problem ever, boo hoo duck
@ 2008-02-20 9:24 ` Avi Kivity
2008-02-20 9:42 ` Avi Kivity
0 siblings, 1 reply; 3+ messages in thread
From: Avi Kivity @ 2008-02-20 9:24 UTC (permalink / raw)
To: duck; +Cc: kvm-devel
duck@sophos.com wrote:
> EIP: [<f8b8dcd2>] vmx_set_efer+0xa2/0xb0 [kvm_intel] SS:ESP 0068:f4a63ed4
>
>
Not completely unexpected. You are running a Core (not 2) processor
which doesn't support nx or x86_64, so it doesn't have the EFER
register. kvm-61 adds support for the EFER on i386, but apparently
doesn't handle those old cpus well.
I'll try to get a patch for you to test.
--
Any sufficiently difficult bug is indistinguishable from a feature.
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Out-of-box kvm-61 driver crash, first kvm problem ever, boo hoo...
2008-02-20 9:24 ` Avi Kivity
@ 2008-02-20 9:42 ` Avi Kivity
0 siblings, 0 replies; 3+ messages in thread
From: Avi Kivity @ 2008-02-20 9:42 UTC (permalink / raw)
To: duck; +Cc: kvm-devel
[-- Attachment #1: Type: text/plain, Size: 513 bytes --]
Avi Kivity wrote:
> duck@sophos.com wrote:
>> EIP: [<f8b8dcd2>] vmx_set_efer+0xa2/0xb0 [kvm_intel] SS:ESP
>> 0068:f4a63ed4
>>
>>
>
> Not completely unexpected. You are running a Core (not 2) processor
> which doesn't support nx or x86_64, so it doesn't have the EFER
> register. kvm-61 adds support for the EFER on i386, but apparently
> doesn't handle those old cpus well.
>
> I'll try to get a patch for you to test.
>
Attached.
--
Any sufficiently difficult bug is indistinguishable from a feature.
[-- Attachment #2: no-efer-on-old-core.patch --]
[-- Type: text/x-patch, Size: 411 bytes --]
diff --git a/kernel/vmx.c b/kernel/vmx.c
index e75b2f5..a575e54 100644
--- a/kernel/vmx.c
+++ b/kernel/vmx.c
@@ -1342,6 +1342,8 @@ static void vmx_set_efer(struct kvm_vcpu *vcpu, u64 efer)
struct kvm_msr_entry *msr = find_msr_entry(vmx, MSR_EFER);
vcpu->arch.shadow_efer = efer;
+ if (!msr)
+ return;
if (efer & EFER_LMA) {
vmcs_write32(VM_ENTRY_CONTROLS,
vmcs_read32(VM_ENTRY_CONTROLS) |
[-- Attachment #3: Type: text/plain, Size: 228 bytes --]
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
[-- Attachment #4: Type: text/plain, Size: 158 bytes --]
_______________________________________________
kvm-devel mailing list
kvm-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-devel
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2008-02-20 9:42 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-02-20 7:45 Out-of-box kvm-61 driver crash, first kvm problem ever, boo hoo duck
2008-02-20 9:24 ` Avi Kivity
2008-02-20 9:42 ` Avi Kivity
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox