From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56014) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zf4fl-0000ri-OD for qemu-devel@nongnu.org; Thu, 24 Sep 2015 07:26:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Zf4fg-0001eM-LP for qemu-devel@nongnu.org; Thu, 24 Sep 2015 07:26:45 -0400 Received: from mga09.intel.com ([134.134.136.24]:52600) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Zf4fg-0001eI-FC for qemu-devel@nongnu.org; Thu, 24 Sep 2015 07:26:40 -0400 Date: Thu, 24 Sep 2015 19:29:04 +0800 From: Yuanhan Liu Message-ID: <20150924112904.GC2326@yliu-dev.sh.intel.com> References: <1442982001-10669-1-git-send-email-yuanhan.liu@linux.intel.com> <1442982001-10669-3-git-send-email-yuanhan.liu@linux.intel.com> <5603CCC4.2060205@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5603CCC4.2060205@redhat.com> Subject: Re: [Qemu-devel] [PATCH v11 2/7] vhost-user: add protocol feature negotiation List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Marcel Apfelbaum Cc: jasowang@redhat.com, mst@redhat.com, qemu-devel@nongnu.org, Changchun.ouyang@hotmail.com On Thu, Sep 24, 2015 at 01:13:24PM +0300, Marcel Apfelbaum wrote: > >diff --git a/hw/net/vhost_net.c b/hw/net/vhost_net.c > >index 1d76b94..9d32d76 100644 > >--- a/hw/net/vhost_net.c > >+++ b/hw/net/vhost_net.c > >@@ -152,8 +152,10 @@ struct vhost_net *vhost_net_init(VhostNetOptions *options) > > net->dev.backend_features = qemu_has_vnet_hdr(options->net_backend) > > ? 0 : (1ULL << VHOST_NET_F_VIRTIO_NET_HDR); > > net->backend = r; > >+ net->dev.protocol_features = 0; > > } else { > > net->dev.backend_features = 0; > >+ net->dev.protocol_features = 0; > > net->backend = -1; > > } > > Maybe protocol_features assignment should be outside the if clause. > (assigned to 0 in both cases) Yeah, we could do that. However, it seems that it will take more effort, for handling patch conflicts while rebase, than it worths. Therefore I will keep it. --yliu