[v2] examples/ipsec-secgw: accept inline proto pkts in single sa

Message ID 20211006072016.8465-1-ndabilpuram@marvell.com (mailing list archive)
State Accepted, archived
Delegated to: akhil goyal
Headers
Series [v2] examples/ipsec-secgw: accept inline proto pkts in single sa |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/iol-broadcom-Functional success Functional Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-broadcom-Performance success Performance Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/github-robot: build success github build: passed
ci/iol-aarch64-compile-testing success Testing PASS
ci/Intel-compilation success Compilation OK
ci/intel-Testing success Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS
ci/iol-x86_64-unit-testing fail Testing issues
ci/iol-mellanox-Performance success Performance Testing PASS

Commit Message

Nithin Dabilpuram Oct. 6, 2021, 7:20 a.m. UTC
  In inline protocol inbound SA's, plain ipv4 and ipv6 packets are
delivered to application unlike inline crypto or lookaside.
Hence fix the application to not drop them when working in
single SA mode.

Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
---

v2:
- Fixed commit message.

 examples/ipsec-secgw/ipsec-secgw.c | 10 ----------
 1 file changed, 10 deletions(-)
  

Comments

Akhil Goyal Oct. 7, 2021, 1:16 p.m. UTC | #1
> Subject: [PATCH v2] examples/ipsec-secgw: accept inline proto pkts in single
> sa
> 
> In inline protocol inbound SA's, plain ipv4 and ipv6 packets are
> delivered to application unlike inline crypto or lookaside.
> Hence fix the application to not drop them when working in
> single SA mode.
> 
> Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
> ---
> 
Acked-by: Akhil Goyal <gakhil@marvell.com>

@Konstantin/Bernard: Any objections?
  
Ananyev, Konstantin Oct. 7, 2021, 3:38 p.m. UTC | #2
> > Subject: [PATCH v2] examples/ipsec-secgw: accept inline proto pkts in single
> > sa
> >
> > In inline protocol inbound SA's, plain ipv4 and ipv6 packets are
> > delivered to application unlike inline crypto or lookaside.
> > Hence fix the application to not drop them when working in
> > single SA mode.
> >
> > Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
> > ---
> >
> Acked-by: Akhil Goyal <gakhil@marvell.com>
> 
> @Konstantin/Bernard: Any objections?

None from me.
  
Akhil Goyal Oct. 16, 2021, 1:34 p.m. UTC | #3
> 
> > > Subject: [PATCH v2] examples/ipsec-secgw: accept inline proto pkts in
> single
> > > sa
> > >
> > > In inline protocol inbound SA's, plain ipv4 and ipv6 packets are
> > > delivered to application unlike inline crypto or lookaside.
> > > Hence fix the application to not drop them when working in
> > > single SA mode.
> > >
> > > Signed-off-by: Nithin Dabilpuram <ndabilpuram@marvell.com>
> > > ---
> > >
> > Acked-by: Akhil Goyal <gakhil@marvell.com>
> >
> > @Konstantin/Bernard: Any objections?
> 
> None from me.

Applied to dpdk-next-crypto
  

Patch

diff --git a/examples/ipsec-secgw/ipsec-secgw.c b/examples/ipsec-secgw/ipsec-secgw.c
index 7ad94cb..96fbae2 100644
--- a/examples/ipsec-secgw/ipsec-secgw.c
+++ b/examples/ipsec-secgw/ipsec-secgw.c
@@ -848,16 +848,6 @@  process_pkts_inbound_nosp(struct ipsec_ctx *ipsec_ctx,
 	struct rte_mbuf *m;
 	uint32_t nb_pkts_in, i, idx;
 
-	/* Drop any IPv4 traffic from unprotected ports */
-	free_pkts(traffic->ip4.pkts, traffic->ip4.num);
-
-	traffic->ip4.num = 0;
-
-	/* Drop any IPv6 traffic from unprotected ports */
-	free_pkts(traffic->ip6.pkts, traffic->ip6.num);
-
-	traffic->ip6.num = 0;
-
 	if (app_sa_prm.enable == 0) {
 
 		nb_pkts_in = ipsec_inbound(ipsec_ctx, traffic->ipsec.pkts,