From: Ingo Molnar Subject: Re: [PATCH 1/2] kvm tools: Respect ISR status in virtio header Date: Sat, 7 May 2011 17:06:51 +0200 Message-ID: <20110507150651.GB5822@elte.hu> References: <1304735660-10844-1-git-send-email-asias.hejun@gmail.com> <20110507093027.GD27657@elte.hu> <4DC545BA.3030501@us.ibm.com> <1304779834.10621.14.camel@jaguar> <4DC55ED3.1080006@us.ibm.com> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Anthony Liguori , Asias He , "Michael S. Tsirkin" , Rusty Russell , Mark McLoughlin , Cyrill Gorcunov , Sasha Levin , Prasad Joshi , kvm@vger.kernel.org To: Pekka Enberg Return-path: Received: from mx2.mail.elte.hu ([157.181.151.9]:41226 "EHLO mx2.mail.elte.hu" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755550Ab1EGPHK (ORCPT ); Sat, 7 May 2011 11:07:10 -0400 Content-Disposition: inline In-Reply-To: Sender: kvm-owner@vger.kernel.org List-ID: * Pekka Enberg wrote: > On Sat, May 7, 2011 at 6:01 PM, Anthony Liguori = wrote: > > On 05/07/2011 09:50 AM, Pekka Enberg wrote: > >> > >> On Sat, 2011-05-07 at 08:14 -0500, Anthony Liguori wrote: > >>> > >>> It seems like this patch is simply avoiding raising the interrupt= line > >>> if the ISR has not been acknowledged yet. =A0I don't think there'= s a > >>> functional issue here but I'm surprised that it's a win. =A0There= should > >>> be a very short window when the interrupt is lowered in the APIC = but > >>> still not acknowledged in the ISR. > >>> > >>> You should just be saving a pretty cheap system call. =A0I wonder= if the > >>> system call is taking longer than it should.. > >> > >> The patch seems to fix a bug where the guest kernel breaks down un= der > >> interrupt storm and stops doing VIRTIO_PCI_QUEUE_NOTIFY. We assume= d it > >> was something with our code but your comments make me wonder if th= ere's > >> a real problem in KVM_IRQ_LINE. > > > > Stops doing it for a short period of time or entirely? >=20 > Seems to be entirely. The test case is doing "ping -f" from host to > guest and vice versa and it takes 30-60 seconds to trigger for me. here's the condition as described by Asias: " I also found when network hangs, guest kernel refuse to give any avai= l=20 buffers in rx queue to device. At that time, vq->last_used_idx equals= =20 vq->vring.used->idx in rx queue, so even with manual IRQ injection us= ing a=20 debug key ctrl-a-i, the network still hangs. " Thanks, Ingo