From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46291) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aHUFO-0001Fk-E3 for qemu-devel@nongnu.org; Fri, 08 Jan 2016 05:26:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aHUFK-0005Q0-Vm for qemu-devel@nongnu.org; Fri, 08 Jan 2016 05:26:18 -0500 Received: from e06smtp16.uk.ibm.com ([195.75.94.112]:41461) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aHUFK-0005Ps-Mu for qemu-devel@nongnu.org; Fri, 08 Jan 2016 05:26:14 -0500 Received: from localhost by e06smtp16.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 8 Jan 2016 10:26:13 -0000 Received: from b06cxnps4076.portsmouth.uk.ibm.com (d06relay13.portsmouth.uk.ibm.com [9.149.109.198]) by d06dlp03.portsmouth.uk.ibm.com (Postfix) with ESMTP id DE0931B08061 for ; Fri, 8 Jan 2016 10:26:51 +0000 (GMT) Received: from d06av03.portsmouth.uk.ibm.com (d06av03.portsmouth.uk.ibm.com [9.149.37.213]) by b06cxnps4076.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id u08AQ9aM1376606 for ; Fri, 8 Jan 2016 10:26:09 GMT Received: from d06av03.portsmouth.uk.ibm.com (localhost [127.0.0.1]) by d06av03.portsmouth.uk.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id u08AQ9Bc021291 for ; Fri, 8 Jan 2016 03:26:09 -0700 Date: Fri, 8 Jan 2016 11:26:05 +0100 From: Greg Kurz Message-ID: <20160108112605.73a81c13@bahia.local> In-Reply-To: <20160108111120.3429b210.cornelia.huck@de.ibm.com> References: <20160107110747.10897.41118.stgit@bahia.huguette.org> <20160107113208.10897.13792.stgit@bahia.huguette.org> <20160108111120.3429b210.cornelia.huck@de.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 2/6] Revert "vhost-net: tell tap backend about the vnet endianness" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Cornelia Huck Cc: qemu-devel@nongnu.org, "Michael S. Tsirkin" On Fri, 8 Jan 2016 11:11:20 +0100 Cornelia Huck wrote: > On Thu, 07 Jan 2016 12:32:08 +0100 > Greg Kurz wrote: > > > This reverts commit 5be7d9f1b1452613b95c6ba70b8d7ad3d0797991. > > > > Cross-endian is now configured by the core virtio-net code. We simply > > fall back on full emulation if the net backend cannot support the > > requested endianness for vnet headers. > > > > Signed-off-by: Greg Kurz > > --- > > hw/net/vhost_net.c | 33 +-------------------------------- > > hw/net/virtio-net.c | 7 +++++++ > > 2 files changed, 8 insertions(+), 32 deletions(-) > > > diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c > > index d4cc94ea5e55..5a0ab6ad5bb5 100644 > > --- a/hw/net/virtio-net.c > > +++ b/hw/net/virtio-net.c > > @@ -128,6 +128,13 @@ static void virtio_net_vhost_status(VirtIONet *n, uint8_t status) > > if (!n->vhost_started) { > > int r, i; > > > > + if (n->needs_vnet_hdr_swap) { > > + error_report("backend does not support %s vnet headers." > > s/./;/ > I'll fix that. > > + "falling back on userspace virtio", > > s/on/to/ > > ? > I thought the same but... http://idioms.thefreedictionary.com/fall+back+on > > + virtio_is_big_endian(vdev) ? "BE" : "LE"); > > + return; > > + } > > + > > /* Any packets outstanding? Purge them to avoid touching rings > > * when vhost is running. > > */ > > > > >