diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-06-09 19:29:42 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-06-10 21:35:01 +0200 |
commit | 59ecec707d7e0bc58095f2413bdaf004efc605e9 (patch) | |
tree | 474cea8fa39c2e79aca78c6a182866bc29f1a60a | |
parent | 0f008dc31133e1fba9f9a14cce107f0274a3776c (diff) |
Revert "net/mlx5: Annotate mutex destroy for root ns"
This reverts commit 95fde2e46860c183f6f47a99381a3b9bff488bd5 which is
commit 9ca415399dae133b00273a4283ef31d003a6818d upstream.
It was backported incorrectly, Paul writes at:
https://lore.kernel.org/r/20200607203425.GD23662@windriver.com
I happened to notice this commit:
9ca415399dae - "net/mlx5: Annotate mutex destroy for root ns"
...was backported to 4.19 and 5.4 and v5.6 in linux-stable.
It patches del_sw_root_ns() - which only exists after v5.7-rc7 from:
6eb7a268a99b - "net/mlx5: Don't maintain a case of del_sw_func being
null"
which creates the one line del_sw_root_ns stub function around
kfree(node) by breaking it out of tree_put_node().
In the absense of del_sw_root_ns - the backport finds an identical one
line kfree stub fcn - named del_sw_prio from this earlier commit:
139ed6c6c46a - "net/mlx5: Fix steering memory leak" [in v4.15-rc5]
and then puts the mutex_destroy() into that (wrong) function, instead of
putting it into tree_put_node where the root ns case used to be hand
Reported-by: Paul Gortmaker <paul.gortmaker@windriver.com>
Cc: Roi Dayan <roid@mellanox.com>
Cc: Mark Bloch <markb@mellanox.com>
Cc: Saeed Mahameed <saeedm@mellanox.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx5/core/fs_core.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c b/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c index 2f6c3353055d..b16e0f45d28c 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c @@ -364,12 +364,6 @@ static void del_sw_ns(struct fs_node *node) static void del_sw_prio(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); } |