[PATCH 2/2] examples/ipsec-secgw: fix issue with IP hdr manipulation
Nithin Dabilpuram
ndabilpuram at marvell.com
Thu Jul 21 17:31:32 CEST 2022
Fix issue with ip header pointer computation to pick the right offset.
Fixes: 6eb3ba03995c ("examples/ipsec-secgw: support poll mode NEON LPM lookup")
Cc: rbhansali at marvell.com
Signed-off-by: Nithin Dabilpuram <ndabilpuram at marvell.com>
---
examples/ipsec-secgw/ipsec_neon.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/examples/ipsec-secgw/ipsec_neon.h b/examples/ipsec-secgw/ipsec_neon.h
index 3f2d0a0..f6ba287 100644
--- a/examples/ipsec-secgw/ipsec_neon.h
+++ b/examples/ipsec-secgw/ipsec_neon.h
@@ -47,7 +47,7 @@ processx4_step3(struct rte_mbuf *pkts[FWDSTEP], uint16_t dst_port[FWDSTEP],
pkt->ol_flags |= tx_offloads;
ip = (struct rte_ipv4_hdr *)
- (p[i] + RTE_ETHER_HDR_LEN + 1);
+ (((uintptr_t)p[i]) + RTE_ETHER_HDR_LEN);
ip->hdr_checksum = 0;
/* calculate IPv4 cksum in SW */
--
2.8.4
More information about the dev
mailing list