[v5,3/8] common/dpaax: fix IOVA table cleanup
Checks
Commit Message
From: Gagandeep Singh <g.singh@nxp.com>
Fixes incorrect structure free
Fixes: 2f3d633aa593 ("common/dpaax: add library for PA/VA translation table")
Cc: stable@dpdk.org
Signed-off-by: Gagandeep Singh <g.singh@nxp.com>
Signed-off-by: Vanshika Shukla <vanshika.shukla@nxp.com>
---
drivers/common/dpaax/dpaax_iova_table.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
@@ -1,5 +1,5 @@
/* SPDX-License-Identifier: BSD-3-Clause
- * Copyright 2018 NXP
+ * Copyright 2018-2023 NXP
*/
#include <rte_memory.h>
@@ -255,10 +255,7 @@ dpaax_iova_table_populate(void)
void
dpaax_iova_table_depopulate(void)
{
- if (dpaax_iova_table_p == NULL)
- return;
-
- rte_free(dpaax_iova_table_p->entries);
+ rte_free(dpaax_iova_table_p);
dpaax_iova_table_p = NULL;
DPAAX_DEBUG("IOVA Table cleaned");