From: Christoph Egger Subject: [PATCH][IOEMU]: Fix ne2k Date: Fri, 28 Mar 2008 11:39:11 +0100 Message-ID: <200803281139.11607.Christoph.Egger@amd.com> Mime-Version: 1.0 Content-Type: Multipart/Mixed; boundary="Boundary-00=_PrM7HfOcPpszO4M" Return-path: List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org --Boundary-00=_PrM7HfOcPpszO4M Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Hi! Attached patch is a backport from qemu upstream: =2D------------------ revision 1.24 date: 2007-04-02 08:19:57 +0000; author: ths; state: Exp; lines: +1 -1; ne2k buffer full bug fix, by Marcel Block. =2D------------------ The patch improves network throughput since otherwise the emulated NICs don't have a way of indicating the receive queue is full and would drop=20 packets. Signed-off-by: Christoph Egger =2D-=20 AMD Saxony, Dresden, Germany Operating System Research Center Legal Information: AMD Saxony Limited Liability Company & Co. KG Sitz (Gesch=E4ftsanschrift): Wilschdorfer Landstr. 101, 01109 Dresden, Deutschland Registergericht Dresden: HRA 4896 vertretungsberechtigter Komplement=E4r: AMD Saxony LLC (Sitz Wilmington, Delaware, USA) Gesch=E4ftsf=FChrer der AMD Saxony LLC: Dr. Hans-R. Deppe, Thomas McCoy --Boundary-00=_PrM7HfOcPpszO4M Content-Type: text/x-diff; charset="us-ascii"; name="tools_ioemu_ne2k.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="tools_ioemu_ne2k.diff" diff -r e7abfeee2808 tools/ioemu/hw/ne2000.c --- a/tools/ioemu/hw/ne2000.c Thu Mar 27 17:25:22 2008 +0000 +++ b/tools/ioemu/hw/ne2000.c Fri Mar 28 13:42:44 2008 +0100 @@ -207,7 +207,7 @@ static int ne2000_buffer_full(NE2000Stat index = s->curpag << 8; boundary = s->boundary << 8; - if (index <= boundary) + if (index < boundary) avail = boundary - index; else avail = (s->stop - s->start) - (index - boundary); --Boundary-00=_PrM7HfOcPpszO4M Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --Boundary-00=_PrM7HfOcPpszO4M--