]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
net/mlx5: Annotate mutex destroy for root ns
authorRoi Dayan <roid@mellanox.com>
Thu, 14 May 2020 20:44:38 +0000 (23:44 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Sat, 23 May 2020 00:28:52 +0000 (17:28 -0700)
Invoke mutex_destroy() to catch any errors.

Fixes: 2cc43b494a6c ("net/mlx5_core: Managing root flow table")
Signed-off-by: Roi Dayan <roid@mellanox.com>
Reviewed-by: Mark Bloch <markb@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/fs_core.c

index 02d0f94eaaad4219614102a14e9c6bb038271054..9620c8650e13dda1f8b02fd0e9208b6c02ea4733 100644 (file)
@@ -2350,6 +2350,12 @@ static int init_root_tree(struct mlx5_flow_steering *steering,
 
 static void del_sw_root_ns(struct fs_node *node)
 {
+       struct mlx5_flow_root_namespace *root_ns;
+       struct mlx5_flow_namespace *ns;
+
+       fs_get_obj(ns, node);
+       root_ns = container_of(ns, struct mlx5_flow_root_namespace, ns);
+       mutex_destroy(&root_ns->chain_lock);
        kfree(node);
 }