As part of npc tear down sequence flow aging resources are cleaned up while they were already cleaned up when last flow with aging action was removed. This leads to double free of some resources.
Fixes: 85e9542d4700 ("common/cnxk: fix flow aging cleanup") Signed-off-by: Harman Kalra <hka...@marvell.com> --- drivers/common/cnxk/roc_npc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/common/cnxk/roc_npc.c b/drivers/common/cnxk/roc_npc.c index 8a951b6360..2b3c90683c 100644 --- a/drivers/common/cnxk/roc_npc.c +++ b/drivers/common/cnxk/roc_npc.c @@ -389,7 +389,8 @@ roc_npc_fini(struct roc_npc *roc_npc) struct npc *npc = roc_npc_to_npc_priv(roc_npc); int rc; - npc_aging_ctrl_thread_destroy(roc_npc); + if (!roc_npc->flow_age.aged_flows_get_thread_exit) + npc_aging_ctrl_thread_destroy(roc_npc); rc = npc_flow_free_all_resources(npc); if (rc) { -- 2.46.0.469.g4590f2e941