Received: from eggs.gnu.org ([140.186.70.92]:47085) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RxCt7-0008H5-T8 for qemu-devel@nongnu.org; Tue, 14 Feb 2012 02:33:23 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RxCt6-0008Px-8G for qemu-devel@nongnu.org; Tue, 14 Feb 2012 02:33:21 -0500 Received: from serv2.oss.ntt.co.jp ([222.151.198.100]:57262) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RxCt5-0008Pd-MI for qemu-devel@nongnu.org; Tue, 14 Feb 2012 02:33:20 -0500 Message-ID: <4F3A0E39.5080807@oss.ntt.co.jp> Date: Tue, 14 Feb 2012 16:33:13 +0900 From: =?UTF-8?B?RmVybmFuZG8gTHVpcyBWw6F6cXVleiBDYW8=?= MIME-Version: 1.0 References: <1327889855.3455.2.camel@nexus.oss.ntt.co.jp> <4F29B89A.3010101@us.ibm.com> <4F2B437A.1050101@oss.ntt.co.jp> In-Reply-To: <4F2B437A.1050101@oss.ntt.co.jp> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH] rtl8139: honor RxOverflow flag in can_receive method List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: Mark McLoughlin , qemu-devel@nongnu.org, "Michael S. Tsirkin" On 02/03/2012 11:16 AM, Fernando Luis V=C3=A1zquez Cao wrote: > On 02/02/2012 07:11 AM, Anthony Liguori wrote: >> On 01/29/2012 08:17 PM, Fernando Luis V=C3=A1zquez Cao wrote: >>> Some drivers (Linux' 8139too among them) rely on the NIC injecting=20 >>> an interrupt >>> in the event of a receive buffer overflow and, accordingly, set the=20 >>> RxOverflow >>> bit in the interrupt mask. Unfortunately rtl8139's can_receive=20 >>> method ignores >>> the RxOverflow flag, which may lead to a situation where rtl8139=20 >>> stops receiving >>> packets (can_receive returns 0) when the receive buffer becomes full. >>> >>> If the driver eventually read from the receive buffer or reset the=20 >>> card the >>> emulator could recover from this situation. However some=20 >>> implementations only >>> do this upon receiving an interrupt with either RxOK or RxOverflow=20 >>> set in the >>> ISR; interrupt that will never come because QEMU's flow control=20 >>> mechanisms would >>> prevent rtl8139 from receiving any packet. >>> >>> Letting packets go through when the overflow interrupt is enabled=20 >>> makes the >>> QEMU emulator compliant to the spec and solves the problem. >>> >>> This patch should fix a relatively common (in our experience)=20 >>> network stall >>> observed when running enterprise distros with rtl8139 as the NIC; in=20 >>> some cases >>> the 8139too device driver gets loaded and when under heavy load the=20 >>> network >>> eventually stops working. >>> >>> Reported-by: Hayato Kakuta >>> Tested-by: Hayato Kakuta >>> Signed-off-by: Fernando Luis Vazquez Cao >> >> Applied. Thanks. > > Hi Anthony, > > It seems that this patch did not make it into the git tree. > Did you find any merge conflicts? ping