From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id BEC4E93D2 for ; Wed, 27 Jan 2016 04:22:23 +0100 (CET) Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by orsmga102.jf.intel.com with ESMTP; 26 Jan 2016 19:22:22 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.22,353,1449561600"; d="scan'208";a="641970362" Received: from yliu-dev.sh.intel.com (HELO yliu-dev) ([10.239.66.49]) by FMSMGA003.fm.intel.com with ESMTP; 26 Jan 2016 19:22:21 -0800 Date: Wed, 27 Jan 2016 11:22:45 +0800 From: Yuanhan Liu To: "Xie, Huawei" Message-ID: <20160127032245.GB4257@yliu-dev.sh.intel.com> References: <1449122773-25510-1-git-send-email-yuanhan.liu@linux.intel.com> <1449122773-25510-5-git-send-email-yuanhan.liu@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) Cc: "dev@dpdk.org" , Victor Kaplansky , "Michael S. Tsirkin" Subject: Re: [dpdk-dev] [PATCH 4/5] vhost: do not use rte_memcpy for virtio_hdr copy X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 27 Jan 2016 03:22:24 -0000 On Wed, Jan 27, 2016 at 02:46:39AM +0000, Xie, Huawei wrote: > On 12/3/2015 2:03 PM, Yuanhan Liu wrote: > > + if (vq->vhost_hlen == sizeof(struct virtio_net_hdr_mrg_rxbuf)) { > > + *(struct virtio_net_hdr_mrg_rxbuf *)(uintptr_t)desc_addr = hdr; > > + } else { > > + *(struct virtio_net_hdr *)(uintptr_t)desc_addr = hdr.hdr; > > + } > > Thanks! > We might simplify this further. Just reset the first two fields flags > and gso_type. What's this "simplification" for? Don't even to say that we will add TSO support, which modifies few more files, such as csum_start: reseting the first two fields only is wrong here. --yliu