2010-02-08 14:28:08

by Alan

[permalink] [raw]
Subject: KVM in -next is somewhat busted

Reliably at boot time with todays -next I get the following:

BUG: unable to handle kernel paging request at 0000000000001028
IP: [<ffffffffa001c4c4>] balloon+0x1a1/0x309 [virtio_balloon]
PGD 2cd42067 PUD 3b9dc067 PMD 0
Oops: 0000 [#1] SMP
last sysfs file: /sys/devices/virtio-pci/virtio4/block/vdd/removable
CPU 3
Pid: 511, comm: vballoon Not tainted 2.6.33-rc7-next-20100208+ #51 /
RIP: 0010:[<ffffffffa001c4c4>] [<ffffffffa001c4c4>] balloon+0x1a1/0x309 [virtio_balloon]
RSP: 0018:ffff88002cd65e40 EFLAGS: 00010282
RAX: ffffea0000d655f2 RBX: ffff88003d3d2800 RCX: ffffea0000000000
RDX: 0000000000000000 RSI: ffff88002cd65e80 RDI: ffff88003d3d2c80
RBP: ffff88002cd65ee0 R08: 0000000000000040 R09: ffffffff81af0c88
R10: ffff88002cc65c80 R11: ffff88002cd65eac R12: 0000000000001000
R13: ffff88003ca61720 R14: ffff88002cd65e80 R15: ffff88003ca61720
FS: 0000000000000000(0000) GS:ffff880001e60000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 000000008005003b
CR2: 0000000000001028 CR3: 000000002cdbd000 CR4: 00000000000006e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
Process vballoon (pid: 511, threadinfo ffff88002cd64000, task ffff88003ca61720)
Stack:
0000000000000001 0000000000000000 ffff88003ca61720 ffff88003d3d2c80
<0> ffff88003d3d2868 ffff88002cd65e98 ffff88003d3d2820 0000000000000000
<0> ffffea0000d655f2 0000003c00000c80 0000000000000000 0000000000000000
Call Trace:
[<ffffffffa001c323>] ? balloon+0x0/0x309 [virtio_balloon]
[<ffffffff81064d75>] kthread+0x7f/0x87
[<ffffffff8100a9a4>] kernel_thread_helper+0x4/0x10
[<ffffffff81064cf6>] ? kthread+0x0/0x87
[<ffffffff8100a9a0>] ? kernel_thread_helper+0x0/0x10
Code: 54 48 89 df c7 83 7c 04 00 00 00 00 00 00 e8 b0 fd ff ff 4c 8b 63 18 48 8b b5 78 ff ff ff ba 3c 00 00 00 4c 89 f7 e8 85 f3 1e e1 <49> 8b 44 24 28 31 c9 49 89 d8 ba 01 00 00 00 4c 89 f6 4c 89 e7
RIP [<ffffffffa001c4c4>] balloon+0x1a1/0x309 [virtio_balloon]
RSP <ffff88002cd65e40>
CR2: 0000000000001028
---[ end trace 2a0ed1359b95aa89 ]---


2010-02-08 14:41:53

by Avi Kivity

[permalink] [raw]
Subject: Re: KVM in -next is somewhat busted

(fixed kvm@ address)


On 02/08/2010 04:27 PM, Alan Cox wrote:
> Reliably at boot time with todays -next I get the following:
>
> BUG: unable to handle kernel paging request at 0000000000001028
> IP: [<ffffffffa001c4c4>] balloon+0x1a1/0x309 [virtio_balloon]
> PGD 2cd42067 PUD 3b9dc067 PMD 0
> Oops: 0000 [#1] SMP
> last sysfs file: /sys/devices/virtio-pci/virtio4/block/vdd/removable
> CPU 3
> Pid: 511, comm: vballoon Not tainted 2.6.33-rc7-next-20100208+ #51 /
> RIP: 0010:[<ffffffffa001c4c4>] [<ffffffffa001c4c4>] balloon+0x1a1/0x309 [virtio_balloon]
>

Looks like the guest is broken, not the host. Do things work if you
leave out CONFIG_VIRTIO_BALLOON?

Copying Adam Litke, who's name is on the latest balloon changes.

--
error compiling committee.c: too many arguments to function

2010-02-08 14:49:05

by Adam Litke

[permalink] [raw]
Subject: Re: KVM in -next is somewhat busted

This is probably fixed by this patch from Rusty... Strangely, I have not
seen this on my test systems.

When running under qemu-kvm-0.11.0:

BUG: unable to handle kernel paging request at 56e58955
...
Process vballoon (pid: 1297, ti=c7976000 task=c70a6ca0 task.ti=c7
...
Call Trace:
[<c88253a3>] ? balloon+0x1b3/0x440 [virtio_balloon]
[<c041c2d7>] ? schedule+0x327/0x9d0
[<c88251f0>] ? balloon+0x0/0x440 [virtio_balloon]
[<c014a2d4>] ? kthread+0x74/0x80
[<c014a260>] ? kthread+0x0/0x80
[<c0103b36>] ? kernel_thread_helper+0x6/0x30

need_stats_update should be zero-initialized.

Signed-off-by: Rusty Russell <[email protected]>
Cc: Adam Litke <[email protected]>

diff --git a/drivers/virtio/virtio_balloon.c b/drivers/virtio/virtio_balloon.c
--- a/drivers/virtio/virtio_balloon.c
+++ b/drivers/virtio/virtio_balloon.c
@@ -292,6 +292,7 @@ static int virtballoon_probe(struct virt
vb->num_pages = 0;
init_waitqueue_head(&vb->config_change);
vb->vdev = vdev;
+ vb->need_stats_update = 0;

/* We expect two virtqueues: inflate and deflate,
* and optionally stat. */


On Mon, 2010-02-08 at 16:41 +0200, Avi Kivity wrote:
> (fixed kvm@ address)
>
>
> On 02/08/2010 04:27 PM, Alan Cox wrote:
> > Reliably at boot time with todays -next I get the following:
> >
> > BUG: unable to handle kernel paging request at 0000000000001028
> > IP: [<ffffffffa001c4c4>] balloon+0x1a1/0x309 [virtio_balloon]
> > PGD 2cd42067 PUD 3b9dc067 PMD 0
> > Oops: 0000 [#1] SMP
> > last sysfs file: /sys/devices/virtio-pci/virtio4/block/vdd/removable
> > CPU 3
> > Pid: 511, comm: vballoon Not tainted 2.6.33-rc7-next-20100208+ #51 /
> > RIP: 0010:[<ffffffffa001c4c4>] [<ffffffffa001c4c4>] balloon+0x1a1/0x309 [virtio_balloon]
> >
>
> Looks like the guest is broken, not the host. Do things work if you
> leave out CONFIG_VIRTIO_BALLOON?
>
> Copying Adam Litke, who's name is on the latest balloon changes.
>


--
Thanks,
Adam