Re: [regression] KVM: hangs and "irq timeout" booting HURD unless -no-kvm-irqchip passed

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

 



On Mon, Feb 07, 2011 at 02:45:13PM +0200, Gleb Natapov wrote:
> On Mon, Feb 07, 2011 at 02:39:01PM +0200, Avi Kivity wrote:
> > On 02/07/2011 08:00 AM, Jonathan Nieder wrote:
> > >Hi kvm-ers,
> > >
> > >When I boot the HURD with
> > >
> > >	kvm -m 768 -net nic,model=ne2k_pci -net user hurd-installed.qemu
> > >
> > >it hangs and eventually produces two messages:
> > >
> > >	hd0: unexpected_intr: status=0x58 { DriveReady SeekComplete DataRequest }
> > >	hd0: irq timeout: status=0x58 { DriveReady Seek Complete DataRequest }
> > >
> > >More details below[1].
> > >
> > >Adding -no-kvm-irqchip to the kvm command line fixes it --- no
> > >more hangs or confusing messages (thanks, Guillem!).
> > >
> > >Bisects (thanks to Michael for the idea) to
> > >
> > >	v2.6.37-rc1~142^2~39 (KVM: Check for pending events before
> > >	attempting injection, 2010-07-27).
> > >
> > >Bisection log and kernel configuration available upon request (but
> > >probably not too relevant --- the 2.6.37 distro kernel from Debian
> > >exhibits the same problem).  Reproducible with kvm/master (2d4b4d26,
> > >2011-02-01).
> > >
> > >CPU is a dual-core AMD Athlon II P360, family 16, model 6.
> > >
> > >Any hints for tracking this down?  For those wanting to follow along
> > >at home, you can find a HURD cd to try at [2].
> > >
> > 
> > Reproduced on AMD, not on Intel.  Given that I see a few PIC and PIT
> > PIOs before the hang, the problem is likely at the PIT.  Will look
> > further.
> > 
> I can reproduce it on Intel. Looking into it. Looks like PIC isr_ack
> problem again.
> 

Is this patch helps?

diff --git a/arch/x86/kvm/i8259.c b/arch/x86/kvm/i8259.c
index 3cece05..62b1dde 100644
--- a/arch/x86/kvm/i8259.c
+++ b/arch/x86/kvm/i8259.c
@@ -549,6 +549,9 @@ static void pic_irq_request(struct kvm *kvm, int level)
 	struct kvm_pic *s = pic_irqchip(kvm);
 	int irq = pic_get_irq(&s->pics[0]);
 
+	if (s->output && !level)
+		s->pics[0].isr_ack = 0xff;
+
 	s->output = level;
 	if (vcpu && level && (s->pics[0].isr_ack & (1 << irq))) {
 		s->pics[0].isr_ack &= ~(1 << irq);
--
			Gleb.
--
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