[dpdk-dev] [PATCH v3 1/2] lpm: fix free of data structure
David Marchand
david.marchand at redhat.com
Fri Oct 23 11:38:17 CEST 2020
From: Ruifeng Wang <ruifeng.wang at arm.com>
The container structure should be freed instead of rte_lpm structure
after wrapping rte_lpm into internal structure __rte_lpm.
Fixes: 8a9f8564e9f9 ("lpm: implement RCU rule reclamation")
Signed-off-by: Ruifeng Wang <ruifeng.wang at arm.com>
Reviewed-by: Phil Yang <phil.yang at arm.com>
Acked-by: Bruce Richardson <bruce.richardson at intel.com>
Acked-by: Vladimir Medvedkin <vladimir.medvedkin at intel.com>
Acked-by: Kevin Traynor <ktraynor at redhat.com>
---
lib/librte_lpm/rte_lpm.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lib/librte_lpm/rte_lpm.c b/lib/librte_lpm/rte_lpm.c
index 757436f492..51a0ae5780 100644
--- a/lib/librte_lpm/rte_lpm.c
+++ b/lib/librte_lpm/rte_lpm.c
@@ -268,7 +268,7 @@ rte_lpm_free(struct rte_lpm *lpm)
rte_rcu_qsbr_dq_delete(internal_lpm->dq);
rte_free(lpm->tbl8);
rte_free(lpm->rules_tbl);
- rte_free(lpm);
+ rte_free(internal_lpm);
rte_free(te);
}
--
2.23.0
More information about the dev
mailing list