From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=42989 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Oxbx5-0001FD-EJ for qemu-devel@nongnu.org; Mon, 20 Sep 2010 04:42:20 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Oxbx4-0001Vs-3O for qemu-devel@nongnu.org; Mon, 20 Sep 2010 04:42:19 -0400 Received: from mx1.redhat.com ([209.132.183.28]:44504) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Oxbx3-0001VW-Sp for qemu-devel@nongnu.org; Mon, 20 Sep 2010 04:42:18 -0400 Message-ID: <4C971E77.1000708@redhat.com> Date: Mon, 20 Sep 2010 10:42:31 +0200 From: Kevin Wolf MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] e1000: Pad short frames to minimum size (60 bytes) References: <1284842625-13920-1-git-send-email-stefanha@linux.vnet.ibm.com> <4C9527D1.4030707@reactos.org> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Stefan Hajnoczi Cc: qemu-devel@nongnu.org, 638955@bugs.launchpad.net, =?ISO-8859-1?Q?Herv=E9_Poussineau?= , Stefan Hajnoczi , "Michael S. Tsirkin" Am 18.09.2010 23:12, schrieb Stefan Hajnoczi: > On Sat, Sep 18, 2010 at 9:57 PM, Herv=E9 Poussineau wrote: >> Another patch creating ARP replies at least 64 bytes long has been >> committed: >> http://git.savannah.gnu.org/cgit/qemu.git/commit/?id=3Ddbf3c4b4baceb91= eb64d09f787cbe92d65188813 >> >> Does it fix your issue? >=20 > No I don't think so. This is an e1000 issue, it will happen if you > use tap networking too. The commit you linked to only affects slirp > and pads its ARP code. >=20 > I think there are two places where the minimum frame length can be enfo= rced: > 1. The NIC emulation code. This is currently how rtl8139, pcnet, and > ne2000 do it. My patch adds the same for e1000. > 2. The net layer. If we're emulating Ethernet then it would be > possible to pad to minimum frame length in common networking code > (net.c). 3. The sender. I think it should be the sender's decision which packet he sends and there's no reason to manipulate it on its way to the guest. If the sender sends too short packets, this is where the bug is. Actually, instead of padding the packet we should already drop it in the device model if RCTL.SBP =3D 0. Does a real Solaris work when it receives the same packet? On the other hand, it seems that we're missing the padding where it actually belongs: when sending packets with TCTL.PSP =3D 1. Did you send the ARP packet from another qemu instance? If so, this might be the real reason. Kevin