From mboxrd@z Thu Jan 1 00:00:00 1970 From: Banashankar KV Subject: Re: pktgen offload checksum flag not able to make it work with pacp packets. Date: Sat, 25 Jan 2014 14:53:44 -0800 Message-ID: References: <4FE91E82-8097-451E-A36D-2F1254573A89@windriver.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Cc: "" To: "Wiles, Roger Keith" Return-path: In-Reply-To: <4FE91E82-8097-451E-A36D-2F1254573A89-CWA4WttNNZF54TAoqtyWWQ@public.gmane.org> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" Hi, Thanks a lot for the reply ! Yes I have checked those examples and had set all those flags. But IP checksum started working after commenting off the txq_flags from the pktgen.c file's tx_conf . And I added the following flag to calculate the tcp checksum. m->ol_flags |= PKT_TX_TCP_CKSUM its calculating the TCP checksum but turning out to be wrong checksum. Thanks Banashankar On Fri, Jan 24, 2014 at 11:44 AM, Wiles, Roger Keith < keith.wiles-CWA4WttNNZF54TAoqtyWWQ@public.gmane.org> wrote: > I have not enabled that feature myself, but I would expect it to work as > long as the hardware does. What does the docs say about enabling hardware > offload support? Did you look at the following files: > > ip_reassembly/ipv4_rsmbl.h: m->ol_flags |= PKT_TX_IP_CKSUM; > ipv4_frag/rte_ipv4_frag.h: out_pkt->ol_flags |= > PKT_TX_IP_CKSUM; > > Thanks > ++Keith > > *Keith Wiles*, Principal Technologist for Networking member of the CTO > office, *Wind River* > mobile 940.213.5533 > [image: Powering 30 Years of Innovation] > > On Jan 24, 2014, at 12:54 PM, Banashankar KV wrote: > > I was modifying a packet in pktgen_pcap_mbuf_ctor() > and after modifying I wanted to offload the checksum calculation to h/w > so I am setting these flags in pktgen_pcap_mbuf_ctor function. > > m->pkt.vlan_macip.f.l2_len = sizeof(struct ether_hdr); > m->pkt.vlan_macip.f.l3_len = sizeof(struct ipv4_hdr); > > m->ol_flags = PKT_TX_IP_CKSUM > > > I even tried with setting .txq_flags = 0 in rte_eth_txconf struct in > pktgen.c. > > But still not able to get the h/w checksum. Am I missing anything ? > > > > Thanks > Banashankar > > >