[v3,2/2] examples/ip_reassembly: Enabling IP checksum offload in mbuf
Checks
Commit Message
As per the documentation to use any IP offload features, application
must set required offload flags into mbuf->ol_flags.
Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
---
examples/ip_reassembly/main.c | 3 +++
1 file changed, 3 insertions(+)
Comments
> As per the documentation to use any IP offload features, application
> must set required offload flags into mbuf->ol_flags.
>
> Signed-off-by: Sunil Kumar Kori <skori@marvell.com>
> ---
> examples/ip_reassembly/main.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/examples/ip_reassembly/main.c b/examples/ip_reassembly/main.c
> index 17b55d4..0ad526c 100644
> --- a/examples/ip_reassembly/main.c
> +++ b/examples/ip_reassembly/main.c
> @@ -353,6 +353,9 @@ struct rte_lpm6_config lpm6_config = {
> struct ether_hdr *);
> ip_hdr = (struct ipv4_hdr *)(eth_hdr + 1);
> }
> +
> + /* update offloading flags */
> + m->ol_flags |= (PKT_TX_IPV4 | PKT_TX_IP_CKSUM);
> }
> ip_dst = rte_be_to_cpu_32(ip_hdr->dst_addr);
>
> --
Acked-by: Konstantin Ananyev <konstantin.ananyev@intel.com>
> 1.8.3.1
@@ -353,6 +353,9 @@ struct rte_lpm6_config lpm6_config = {
struct ether_hdr *);
ip_hdr = (struct ipv4_hdr *)(eth_hdr + 1);
}
+
+ /* update offloading flags */
+ m->ol_flags |= (PKT_TX_IPV4 | PKT_TX_IP_CKSUM);
}
ip_dst = rte_be_to_cpu_32(ip_hdr->dst_addr);