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 438521288 for ; Fri, 16 Jan 2015 01:56:58 +0100 (CET) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga102.jf.intel.com with ESMTP; 15 Jan 2015 16:54:11 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.09,407,1418112000"; d="scan'208";a="513026799" Received: from kmsmsx151.gar.corp.intel.com ([172.21.73.86]) by orsmga003.jf.intel.com with ESMTP; 15 Jan 2015 16:50:38 -0800 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by KMSMSX151.gar.corp.intel.com (172.21.73.86) with Microsoft SMTP Server (TLS) id 14.3.195.1; Fri, 16 Jan 2015 08:56:54 +0800 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.238]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.192]) with mapi id 14.03.0195.001; Fri, 16 Jan 2015 08:56:52 +0800 From: "Ouyang, Changchun" To: Stephen Hemminger Thread-Topic: [PATCH 22/22] virtio: Use soft vlan strip in mergeable Rx path Thread-Index: AQHQMIJ1Q9C2nKj1n0uUGm9HDYfFlJzA4SKAgAEMPjA= Date: Fri, 16 Jan 2015 00:56:52 +0000 Message-ID: References: <1421298930-15210-1-git-send-email-changchun.ouyang@intel.com> <1421298930-15210-23-git-send-email-changchun.ouyang@intel.com> <20150115085557.0d4c147f@urahara> In-Reply-To: <20150115085557.0d4c147f@urahara> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" Subject: Re: [dpdk-dev] [PATCH 22/22] virtio: Use soft vlan strip in mergeable Rx path 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: Fri, 16 Jan 2015 00:56:59 -0000 > -----Original Message----- > From: Stephen Hemminger [mailto:stephen@networkplumber.org] > Sent: Friday, January 16, 2015 12:56 AM > To: Ouyang, Changchun > Cc: dev@dpdk.org; Doherty, Declan; Cao, Waterman > Subject: Re: [PATCH 22/22] virtio: Use soft vlan strip in mergeable Rx pa= th >=20 > On Thu, 15 Jan 2015 13:15:30 +0800 > Ouyang Changchun wrote: >=20 > > To keep the consistent logic with normal Rx path, the mergeable Rx > > path also needs software vlan strip/decap if it is enabled. > > > > Signed-off-by: Changchun Ouyang > > --- > > lib/librte_pmd_virtio/virtio_rxtx.c | 4 ++++ > > 1 file changed, 4 insertions(+) > > > > diff --git a/lib/librte_pmd_virtio/virtio_rxtx.c > > b/lib/librte_pmd_virtio/virtio_rxtx.c > > index 2529dc4..9090613 100644 > > --- a/lib/librte_pmd_virtio/virtio_rxtx.c > > +++ b/lib/librte_pmd_virtio/virtio_rxtx.c > > @@ -568,6 +568,7 @@ virtio_recv_mergeable_pkts(void *rx_queue, > > uint16_t nb_pkts) > > { > > struct virtqueue *rxvq =3D rx_queue; > > + struct virtio_hw *hw =3D rxvq->hw; > > struct rte_mbuf *rxm, *new_mbuf; > > uint16_t nb_used, num, nb_rx =3D 0; > > uint32_t len[VIRTIO_MBUF_BURST_SZ]; > > @@ -674,6 +675,9 @@ virtio_recv_mergeable_pkts(void *rx_queue, > > seg_res -=3D rcv_cnt; > > } > > > > + if (hw->vlan_strip) > > + rte_vlan_strip(rx_pkts[nb_rx]); > > + > > VIRTIO_DUMP_PACKET(rx_pkts[nb_rx], > > rx_pkts[nb_rx]->data_len); > > >=20 > If you resubmit, just combine this with earlier patch that does vlan stri= p I think just keeping it as a separate a patch may be a good way. Thanks Changchun