On 8/20/22 04:31, Hernan Vargas wrote:
Set local pointer to NULL after rte_free.
This needs to be set explicitly since logic may check for null pointers.
Fixes: 060e7672930 ("baseband/acc100: add queue configuration")
Cc: [email protected]
Signed-off-by: Hernan Vargas <[email protected]>
---
drivers/baseband/acc100/rte_acc100_pmd.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/baseband/acc100/rte_acc100_pmd.c
b/drivers/baseband/acc100/rte_acc100_pmd.c
index be4c1d07ed..7755d6402f 100644
--- a/drivers/baseband/acc100/rte_acc100_pmd.c
+++ b/drivers/baseband/acc100/rte_acc100_pmd.c
@@ -793,6 +793,9 @@ acc100_dev_close(struct rte_bbdev *dev)
rte_free(d->sw_rings_base);
rte_free(d->harq_layout);
d->sw_rings_base = NULL;
+ d->tail_ptrs = NULL;
+ d->info_ring = NULL;
+ d->harq_layout = NULL;
}
/* Ensure all in flight HW transactions are completed */
usleep(ACC100_LONG_WAIT);
Please move it to the top of the series as this is a fix.
Reviewed-by: Maxime Coquelin <[email protected]>
Thanks,
Maxime