ip_frag: remove IP checkum offload flag
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. Also, IPv6 does not contain any checksum field in header so setting mbuf->ol_flags with PKT_TX_IP_CKSUM is itself invalid. So removing mentioned flag from the library. Signed-off-by: Sunil Kumar Kori <skori@marvell.com> Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
This commit is contained in:
parent
d32411d034
commit
e29fc44370
@ -240,6 +240,21 @@ API Changes
|
||||
announced at least one release before the ABI change is made. There are no
|
||||
ABI breaking changes planned.
|
||||
|
||||
* ip_frag: IP fragmentation library converts input mbuf into fragments
|
||||
using input MTU size via ``rte_ipv4_fragment_packet`` interface.
|
||||
Once fragmentation is done, each ``mbuf->ol_flags`` are set to enable IP
|
||||
checksum H/W offload irrespective of the platform capability.
|
||||
Cleared IP checksum H/W offload flag from the library. The application must
|
||||
set this flag if it is supported by the platform and application wishes to
|
||||
use it.
|
||||
|
||||
* ip_frag: IP reassembly library converts the list of fragments into a
|
||||
reassembled packet via ``rte_ipv4_frag_reassemble_packet`` interface.
|
||||
Once reassembly is done, ``mbuf->ol_flags`` are set to enable IP checksum H/W
|
||||
offload irrespective of the platform capability. Cleared IP checksum H/W
|
||||
offload flag from the library. The application must set this flag if it is
|
||||
supported by the platform and application wishes to use it.
|
||||
|
||||
|
||||
ABI Changes
|
||||
-----------
|
||||
|
@ -66,9 +66,6 @@ ipv4_frag_reassemble(struct ip_frag_pkt *fp)
|
||||
m = fp->frags[IP_FIRST_FRAG_IDX].mb;
|
||||
fp->frags[IP_FIRST_FRAG_IDX].mb = NULL;
|
||||
|
||||
/* update mbuf fields for reassembled packet. */
|
||||
m->ol_flags |= PKT_TX_IP_CKSUM;
|
||||
|
||||
/* update ipv4 header for the reassembled packet */
|
||||
ip_hdr = rte_pktmbuf_mtod_offset(m, struct rte_ipv4_hdr *, m->l2_len);
|
||||
|
||||
|
@ -89,9 +89,6 @@ ipv6_frag_reassemble(struct ip_frag_pkt *fp)
|
||||
m = fp->frags[IP_FIRST_FRAG_IDX].mb;
|
||||
fp->frags[IP_FIRST_FRAG_IDX].mb = NULL;
|
||||
|
||||
/* update mbuf fields for reassembled packet. */
|
||||
m->ol_flags |= PKT_TX_IP_CKSUM;
|
||||
|
||||
/* update ipv6 header for the reassembled datagram */
|
||||
ip_hdr = rte_pktmbuf_mtod_offset(m, struct rte_ipv6_hdr *, m->l2_len);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user