From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 12D26A05D3 for ; Mon, 20 May 2019 13:28:41 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 10620568A; Mon, 20 May 2019 13:28:40 +0200 (CEST) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id DFA255592 for ; Mon, 20 May 2019 13:28:38 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga105.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 20 May 2019 04:28:37 -0700 X-ExtLoop1: 1 Received: from irsmsx101.ger.corp.intel.com ([163.33.3.153]) by fmsmga006.fm.intel.com with ESMTP; 20 May 2019 04:28:36 -0700 Received: from irsmsx105.ger.corp.intel.com ([169.254.7.155]) by IRSMSX101.ger.corp.intel.com ([169.254.1.10]) with mapi id 14.03.0415.000; Mon, 20 May 2019 12:28:35 +0100 From: "Ananyev, Konstantin" To: Sunil Kumar Kori CC: "dev@dpdk.org" Thread-Topic: [PATCH v3 1/2] examples/ip_fragmentation: Enabling IP checksum offload in mbuf Thread-Index: AQHVDvs8tzbI/+z3B0K3uftW08DRfKZz4C6w Date: Mon, 20 May 2019 11:28:35 +0000 Message-ID: <2601191342CEEE43887BDE71AB97725801616361FA@irsmsx105.ger.corp.intel.com> References: <1558006933-32247-3-git-send-email-skori@marvell.com> <1558349992-12237-1-git-send-email-skori@marvell.com> In-Reply-To: <1558349992-12237-1-git-send-email-skori@marvell.com> Accept-Language: en-IE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZjIxMmY1ZDUtOGU2Yi00Yjg5LTlkYTMtNzRkNDdkMjJkZjBmIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiTFU4eml3QldKXC95aHNtVW5sQ2JHY2NJS0piK3Fpd0sycGFyWnVUOXFzUHljekJBTlA3U1YwOXFiMW5HR3ZuWFkifQ== x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.0.600.7 dlp-reaction: no-action x-originating-ip: [163.33.239.182] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH v3 1/2] examples/ip_fragmentation: Enabling IP checksum offload in mbuf X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > As per the documentation to use any IP offload features, application > must set required offload flags into mbuf->ol_flags. >=20 > Signed-off-by: Sunil Kumar Kori > --- > examples/ip_fragmentation/main.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) >=20 > diff --git a/examples/ip_fragmentation/main.c b/examples/ip_fragmentation= /main.c > index e90a61e..719d6f4 100644 > --- a/examples/ip_fragmentation/main.c > +++ b/examples/ip_fragmentation/main.c > @@ -354,10 +354,12 @@ struct rte_lpm6_config lpm6_config =3D { >=20 > /* src addr */ > ether_addr_copy(&ports_eth_addr[port_out], ð_hdr->s_addr); > - if (ipv6) > + if (ipv6) { > eth_hdr->ether_type =3D rte_be_to_cpu_16(ETHER_TYPE_IPv6); > - else > + } else { > eth_hdr->ether_type =3D rte_be_to_cpu_16(ETHER_TYPE_IPv4); > + m->ol_flags |=3D (PKT_TX_IPV4 | PKT_TX_IP_CKSUM); > + } > } >=20 > len +=3D len2; > -- Acked-by: Konstantin Ananyev > 1.8.3.1