From 01af3d0a416130e91c159147f590f9d07da4e767 Mon Sep 17 00:00:00 2001 From: Shougang Wang Date: Wed, 13 Nov 2019 01:37:57 +0000 Subject: [PATCH] net/ice: fix flow director counter resource release All the counter resources should be cleaned up when teardown. Fixes: 0f880c3df192 ("net/ice: add flow director counter resource init/release") Signed-off-by: Shougang Wang Acked-by: Qi Zhang Acked-by: Xiaolong Ye --- drivers/net/ice/ice_fdir_filter.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/net/ice/ice_fdir_filter.c b/drivers/net/ice/ice_fdir_filter.c index 39c0efbdc6..e3b633e232 100644 --- a/drivers/net/ice/ice_fdir_filter.c +++ b/drivers/net/ice/ice_fdir_filter.c @@ -252,6 +252,9 @@ ice_fdir_counter_release(struct ice_pf *pf) for (i = 0; i < container->index_free; i++) rte_free(container->pools[i]); + TAILQ_INIT(&container->pool_list); + container->index_free = 0; + return 0; }