lib/librte_ip_frag: Remove PKT_TX_IP_CKSUM offload flags

Message ID 1563178677-16356-1-git-send-email-skori@marvell.com (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series lib/librte_ip_frag: Remove PKT_TX_IP_CKSUM offload flags |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK
ci/mellanox-Performance-Testing success Performance Testing PASS
ci/intel-Performance-Testing success Performance Testing PASS

Commit Message

Sunil Kumar Kori July 15, 2019, 8:17 a.m. UTC
  Currently PKT_TX_IP_CKSUM is being set into mbuf->ol_flags
during fragmentation and reassemble operation implicitly.
Because of this, application is forced to use checksum offload
whether it is supported by platform or not.

Also documentation does not provide any expected value of ol_flags
in returned mbuf (reassembled or fragmented) so application will never
come to know that which offloads are enabled. So transmission may be failed
for the platforms which does not support checksum offload.

So removing mentioned flag from the library.

Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
---

Current patch is part of following patchset
http://patches.dpdk.org/patch/53475/
which is missed to be merged into upstream because of accepted version of this
patch does not contain this change.

Accepted patchset is given below:
http://patches.dpdk.org/patch/56202/

Patchset is already reviewed and acked on maillist. Also corrersponding release
notes are updated.


 lib/librte_ip_frag/rte_ipv4_fragmentation.c | 1 -
 1 file changed, 1 deletion(-)
  

Comments

Thomas Monjalon July 15, 2019, 10:05 p.m. UTC | #1
15/07/2019 10:17, Sunil Kumar Kori:
> Current patch is part of following patchset
> http://patches.dpdk.org/patch/53475/
> which is missed to be merged into upstream because of accepted version of this
> patch does not contain this change.
> 
> Accepted patchset is given below:
> http://patches.dpdk.org/patch/56202/
> 
> Patchset is already reviewed and acked on maillist. Also corrersponding release
> notes are updated.
[..]
> --- a/lib/librte_ip_frag/rte_ipv4_fragmentation.c
> +++ b/lib/librte_ip_frag/rte_ipv4_fragmentation.c
> -		out_pkt->ol_flags |= PKT_TX_IP_CKSUM;
>  		out_pkt->l3_len = sizeof(struct rte_ipv4_hdr);

Jerin, what happened? A part of the patch was missing?
Is this patch really required?
If this patch is required, the commit log must be changed.
  
Jerin Jacob Kollanukkaran July 16, 2019, 5:41 a.m. UTC | #2
> -----Original Message-----
> From: Thomas Monjalon <thomas@monjalon.net>
> Sent: Tuesday, July 16, 2019 3:35 AM
> To: Sunil Kumar Kori <skori@marvell.com>; Jerin Jacob Kollanukkaran
> <jerinj@marvell.com>
> Cc: dev@dpdk.org; Konstantin Ananyev <konstantin.ananyev@intel.com>
> Subject: Re: [dpdk-dev] [PATCH] lib/librte_ip_frag: Remove
> PKT_TX_IP_CKSUM offload flags
> 
> 15/07/2019 10:17, Sunil Kumar Kori:
> > Current patch is part of following patchset
> > http://patches.dpdk.org/patch/53475/
> > which is missed to be merged into upstream because of accepted version
> > of this patch does not contain this change.
> >
> > Accepted patchset is given below:
> > http://patches.dpdk.org/patch/56202/
> >
> > Patchset is already reviewed and acked on maillist. Also
> > corrersponding release notes are updated.
> [..]
> > --- a/lib/librte_ip_frag/rte_ipv4_fragmentation.c
> > +++ b/lib/librte_ip_frag/rte_ipv4_fragmentation.c
> > -		out_pkt->ol_flags |= PKT_TX_IP_CKSUM;
> >  		out_pkt->l3_len = sizeof(struct rte_ipv4_hdr);
> 
> Jerin, what happened? A part of the patch was missing?

Yes. It was my bad. On rebase to top of tree, due to rename of ipv4_hdr to rte_ipv4_hdr and similar,
Those patches need to be manually rebased.

> Is this patch really required?

Yes.

> If this patch is required, the commit log must be changed.

Yes.

>
  
Sunil Kumar Kori July 16, 2019, 6:28 a.m. UTC | #3
Regards
Sunil Kumar Kori

>-----Original Message-----
>From: Jerin Jacob Kollanukkaran
>Sent: Tuesday, July 16, 2019 11:12 AM
>To: Thomas Monjalon <thomas@monjalon.net>; Sunil Kumar Kori
><skori@marvell.com>
>Cc: dev@dpdk.org; Konstantin Ananyev <konstantin.ananyev@intel.com>
>Subject: RE: [dpdk-dev] [PATCH] lib/librte_ip_frag: Remove PKT_TX_IP_CKSUM
>offload flags
>
>> -----Original Message-----
>> From: Thomas Monjalon <thomas@monjalon.net>
>> Sent: Tuesday, July 16, 2019 3:35 AM
>> To: Sunil Kumar Kori <skori@marvell.com>; Jerin Jacob Kollanukkaran
>> <jerinj@marvell.com>
>> Cc: dev@dpdk.org; Konstantin Ananyev <konstantin.ananyev@intel.com>
>> Subject: Re: [dpdk-dev] [PATCH] lib/librte_ip_frag: Remove
>> PKT_TX_IP_CKSUM offload flags
>>
>> 15/07/2019 10:17, Sunil Kumar Kori:
>> > Current patch is part of following patchset
>> > http://patches.dpdk.org/patch/53475/
>> > which is missed to be merged into upstream because of accepted
>> > version of this patch does not contain this change.
>> >
>> > Accepted patchset is given below:
>> > http://patches.dpdk.org/patch/56202/
>> >
>> > Patchset is already reviewed and acked on maillist. Also
>> > corrersponding release notes are updated.
>> [..]
>> > --- a/lib/librte_ip_frag/rte_ipv4_fragmentation.c
>> > +++ b/lib/librte_ip_frag/rte_ipv4_fragmentation.c
>> > -		out_pkt->ol_flags |= PKT_TX_IP_CKSUM;
>> >  		out_pkt->l3_len = sizeof(struct rte_ipv4_hdr);
>>
>> Jerin, what happened? A part of the patch was missing?
>
>Yes. It was my bad. On rebase to top of tree, due to rename of ipv4_hdr to
>rte_ipv4_hdr and similar, Those patches need to be manually rebased.
>
>> Is this patch really required?
>
>Yes.
>
>> If this patch is required, the commit log must be changed.
>
>Yes.
Next version is updated for this patch after modifying the commit message.
>
>>
  

Patch

diff --git a/lib/librte_ip_frag/rte_ipv4_fragmentation.c b/lib/librte_ip_frag/rte_ipv4_fragmentation.c
index 221d74e..9e9f986 100644
--- a/lib/librte_ip_frag/rte_ipv4_fragmentation.c
+++ b/lib/librte_ip_frag/rte_ipv4_fragmentation.c
@@ -173,7 +173,6 @@  static inline void __free_fragments(struct rte_mbuf *mb[], uint32_t num)
 		fragment_offset = (uint16_t)(fragment_offset +
 		    out_pkt->pkt_len - sizeof(struct rte_ipv4_hdr));
 
-		out_pkt->ol_flags |= PKT_TX_IP_CKSUM;
 		out_pkt->l3_len = sizeof(struct rte_ipv4_hdr);
 
 		/* Write the fragment to the output list */