From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1O1RVy-0006aS-1R for qemu-devel@nongnu.org; Mon, 12 Apr 2010 17:49:54 -0400 Received: from [140.186.70.92] (port=42094 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1O1RVw-0006aA-PK for qemu-devel@nongnu.org; Mon, 12 Apr 2010 17:49:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1O1RVv-0005vk-Ag for qemu-devel@nongnu.org; Mon, 12 Apr 2010 17:49:52 -0400 Received: from mail2.shareable.org ([80.68.89.115]:50436) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1O1RVv-0005vR-3y for qemu-devel@nongnu.org; Mon, 12 Apr 2010 17:49:51 -0400 Date: Mon, 12 Apr 2010 22:49:47 +0100 From: Jamie Lokier Subject: Re: [Qemu-devel] How to lock-up your tap-based VM network Message-ID: <20100412214947.GC6148@shareable.org> References: <4BC34D95.7050804@siemens.com> <201004122107.19425.paul@codesourcery.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201004122107.19425.paul@codesourcery.com> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paul Brook Cc: Jan Kiszka , qemu-devel@nongnu.org Paul Brook wrote: > > A major reason for this deadlock could likely be removed by shutting > > down the tap (if peered) or dropping packets in user space (in case of > > vlan) when a NIC is stopped or otherwise shut down. Currently most (if > > not all) NIC models seem to signal both "queue full" and "RX disabled" > > via !can_receive(). > > No. A disabled device should return true from can_recieve, then discard the > packets in its receive callback. Failure to do so is a bug in the device. It > looks like the virtio-net device may be buggy. I agree - or alternatively signal that there's no point sending it packets and they should be dropped without bothering to construct them. But anyway, this flow control mechanism is buggy - what if instead of an interface down, you just have a *slow* guest? That should not push back so much that it makes other guests networking with each other slow down. -- Jamie