From: Erez Shitrit <[email protected]>
This patch fixes the order dereferencing default FDB miss table and
destroying the flow table object. Flow table should be destroyed
before the dereference.
Fixes: 394cc7ba4033 ("net/mlx5/hws: add table object")
Cc: [email protected]
Signed-off-by: Erez Shitrit <[email protected]>
Signed-off-by: Dariusz Sosnowski <[email protected]>
Reviewed-by: Alex Vesker <[email protected]>
---
drivers/net/mlx5/hws/mlx5dr_table.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/mlx5/hws/mlx5dr_table.c
b/drivers/net/mlx5/hws/mlx5dr_table.c
index d3f77e4780..33052abce8 100644
--- a/drivers/net/mlx5/hws/mlx5dr_table.c
+++ b/drivers/net/mlx5/hws/mlx5dr_table.c
@@ -131,8 +131,8 @@ mlx5dr_table_create_default_ft(struct mlx5dr_table *tbl)
void mlx5dr_table_destroy_default_ft(struct mlx5dr_table *tbl,
struct mlx5dr_devx_obj *ft_obj)
{
- mlx5dr_table_down_default_fdb_miss_tbl(tbl);
mlx5dr_cmd_destroy_obj(ft_obj);
+ mlx5dr_table_down_default_fdb_miss_tbl(tbl);
}
static int mlx5dr_table_init(struct mlx5dr_table *tbl)
--
2.25.1