DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH v2 3/4] examples/ipsec-secgw: use ipsec fcn to access private area
@ 2018-06-18 23:36 Dan Gora
  0 siblings, 0 replies; only message in thread
From: Dan Gora @ 2018-06-18 23:36 UTC (permalink / raw)
  To: dev
  Cc: Dan Gora, Remy Horton, Ori Kam, Bruce Richardson, Pablo de Lara,
	Radu Nicolau, Akhil Goyal, Tomasz Kantecki

In inbound_sa_check(), use the application's get_priv() function to
access the private area in the mbuf.

Signed-off-by: Dan Gora <dg@adax.com>
---
 examples/ipsec-secgw/sa.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/examples/ipsec-secgw/sa.c b/examples/ipsec-secgw/sa.c
index d9dcc0e06..4ab8e098a 100644
--- a/examples/ipsec-secgw/sa.c
+++ b/examples/ipsec-secgw/sa.c
@@ -939,7 +939,7 @@ inbound_sa_check(struct sa_ctx *sa_ctx, struct rte_mbuf *m, uint32_t sa_idx)
 {
 	struct ipsec_mbuf_metadata *priv;
 
-	priv = RTE_PTR_ADD(m, sizeof(struct rte_mbuf));
+	priv = get_priv(m);
 
 	return (sa_ctx->sa[sa_idx].spi == priv->sa->spi);
 }
-- 
2.18.0.rc1.1.g6f333ff2f

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2018-06-18 23:37 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-18 23:36 [dpdk-dev] [PATCH v2 3/4] examples/ipsec-secgw: use ipsec fcn to access private area Dan Gora

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).