All of lore.kernel.org
 help / color / mirror / Atom feed
* [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06
@ 2019-11-06 22:05 Saeed Mahameed
  2019-11-06 22:05 ` [net 1/4] net/mlx5e: Fix eswitch debug print of max fdb flow Saeed Mahameed
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Saeed Mahameed @ 2019-11-06 22:05 UTC (permalink / raw)
  To: David S. Miller; +Cc: netdev, Saeed Mahameed

Hi Dave,

This series introduces some fixes to mlx5 driver.

Please pull and let me know if there is any problem.

No -stable this time.

Thanks,
Saeed.

---
The following changes since commit cc59dbcc5ddda532c9da054977d2dfc8f7338735:

  Merge branch 'net-bcmgenet-restore-internal-EPHY-support' (2019-11-06 10:46:22 -0800)

are available in the Git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/saeed/linux.git tags/mlx5-fixes-2019-11-06

for you to fetch changes up to 950d3af70ea89cf7ac51d734a634174013631192:

  net/mlx5e: Use correct enum to determine uplink port (2019-11-06 14:03:55 -0800)

----------------------------------------------------------------
mlx5-fixes-2019-11-06

----------------------------------------------------------------
Alex Vesker (2):
      net/mlx5: DR, Fix memory leak in modify action destroy
      net/mlx5: DR, Fix memory leak during rule creation

Dmytro Linkin (1):
      net/mlx5e: Use correct enum to determine uplink port

Roi Dayan (1):
      net/mlx5e: Fix eswitch debug print of max fdb flow

 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c         | 2 +-
 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads_termtbl.c | 3 ++-
 drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c       | 1 +
 drivers/net/ethernet/mellanox/mlx5/core/steering/dr_rule.c         | 2 ++
 4 files changed, 6 insertions(+), 2 deletions(-)

^ permalink raw reply	[flat|nested] 6+ messages in thread

* [net 1/4] net/mlx5e: Fix eswitch debug print of max fdb flow
  2019-11-06 22:05 [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 Saeed Mahameed
@ 2019-11-06 22:05 ` Saeed Mahameed
  2019-11-06 22:05 ` [net 2/4] net/mlx5: DR, Fix memory leak in modify action destroy Saeed Mahameed
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Saeed Mahameed @ 2019-11-06 22:05 UTC (permalink / raw)
  To: David S. Miller; +Cc: netdev, Roi Dayan, Eli Britstein, Saeed Mahameed

From: Roi Dayan <roid@mellanox.com>

The value is already the calculation so remove the log prefix.

Fixes: e52c28024008 ("net/mlx5: E-Switch, Add chains and priorities")
Signed-off-by: Roi Dayan <roid@mellanox.com>
Reviewed-by: Eli Britstein <elibr@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
---
 drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c b/drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c
index 369499e88fe8..9004a07e457a 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads.c
@@ -1079,7 +1079,7 @@ static int esw_create_offloads_fdb_tables(struct mlx5_eswitch *esw, int nvports)
 			    MLX5_CAP_GEN(dev, max_flow_counter_15_0);
 	fdb_max = 1 << MLX5_CAP_ESW_FLOWTABLE_FDB(dev, log_max_ft_size);
 
-	esw_debug(dev, "Create offloads FDB table, min (max esw size(2^%d), max counters(%d), groups(%d), max flow table size(2^%d))\n",
+	esw_debug(dev, "Create offloads FDB table, min (max esw size(2^%d), max counters(%d), groups(%d), max flow table size(%d))\n",
 		  MLX5_CAP_ESW_FLOWTABLE_FDB(dev, log_max_ft_size),
 		  max_flow_counter, ESW_OFFLOADS_NUM_GROUPS,
 		  fdb_max);
-- 
2.21.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [net 2/4] net/mlx5: DR, Fix memory leak in modify action destroy
  2019-11-06 22:05 [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 Saeed Mahameed
  2019-11-06 22:05 ` [net 1/4] net/mlx5e: Fix eswitch debug print of max fdb flow Saeed Mahameed
@ 2019-11-06 22:05 ` Saeed Mahameed
  2019-11-06 22:05 ` [net 3/4] net/mlx5: DR, Fix memory leak during rule creation Saeed Mahameed
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Saeed Mahameed @ 2019-11-06 22:05 UTC (permalink / raw)
  To: David S. Miller; +Cc: netdev, Alex Vesker, Saeed Mahameed

From: Alex Vesker <valex@mellanox.com>

The rewrite data was no freed.

Fixes: 9db810ed2d37 ("net/mlx5: DR, Expose steering action functionality")
Signed-off-by: Alex Vesker <valex@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
---
 drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c b/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c
index b74b7d0f6590..004c56c2fc0c 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_action.c
@@ -1577,6 +1577,7 @@ int mlx5dr_action_destroy(struct mlx5dr_action *action)
 		break;
 	case DR_ACTION_TYP_MODIFY_HDR:
 		mlx5dr_icm_free_chunk(action->rewrite.chunk);
+		kfree(action->rewrite.data);
 		refcount_dec(&action->rewrite.dmn->refcount);
 		break;
 	default:
-- 
2.21.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [net 3/4] net/mlx5: DR, Fix memory leak during rule creation
  2019-11-06 22:05 [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 Saeed Mahameed
  2019-11-06 22:05 ` [net 1/4] net/mlx5e: Fix eswitch debug print of max fdb flow Saeed Mahameed
  2019-11-06 22:05 ` [net 2/4] net/mlx5: DR, Fix memory leak in modify action destroy Saeed Mahameed
@ 2019-11-06 22:05 ` Saeed Mahameed
  2019-11-06 22:05 ` [net 4/4] net/mlx5e: Use correct enum to determine uplink port Saeed Mahameed
  2019-11-07  5:40 ` [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 David Miller
  4 siblings, 0 replies; 6+ messages in thread
From: Saeed Mahameed @ 2019-11-06 22:05 UTC (permalink / raw)
  To: David S. Miller; +Cc: netdev, Alex Vesker, Saeed Mahameed

From: Alex Vesker <valex@mellanox.com>

During rule creation hw_ste_arr was not freed.

Fixes: 41d07074154c ("net/mlx5: DR, Expose steering rule functionality")
Signed-off-by: Alex Vesker <valex@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
---
 drivers/net/ethernet/mellanox/mlx5/core/steering/dr_rule.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_rule.c b/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_rule.c
index e8b656075c6f..5dcb8baf491a 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_rule.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/steering/dr_rule.c
@@ -1096,6 +1096,8 @@ dr_rule_create_rule_nic(struct mlx5dr_rule *rule,
 	if (htbl)
 		mlx5dr_htbl_put(htbl);
 
+	kfree(hw_ste_arr);
+
 	return 0;
 
 free_ste:
-- 
2.21.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* [net 4/4] net/mlx5e: Use correct enum to determine uplink port
  2019-11-06 22:05 [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 Saeed Mahameed
                   ` (2 preceding siblings ...)
  2019-11-06 22:05 ` [net 3/4] net/mlx5: DR, Fix memory leak during rule creation Saeed Mahameed
@ 2019-11-06 22:05 ` Saeed Mahameed
  2019-11-07  5:40 ` [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 David Miller
  4 siblings, 0 replies; 6+ messages in thread
From: Saeed Mahameed @ 2019-11-06 22:05 UTC (permalink / raw)
  To: David S. Miller
  Cc: netdev, Dmytro Linkin, Vlad Buslov, Roi Dayan, Saeed Mahameed

From: Dmytro Linkin <dmitrolin@mellanox.com>

For vlan push action, if eswitch flow source capability is enabled, flow
source value compared with MLX5_VPORT_UPLINK enum, to determine uplink
port. This lead to syndrome in dmesg if try to add vlan push action.
For example:
 $ tc filter add dev vxlan0 ingress protocol ip prio 1 flower \
       enc_dst_port 4789 \
       action tunnel_key unset pipe \
       action vlan push id 20 pipe \
       action mirred egress redirect dev ens1f0_0
 $ dmesg
 ...
 [ 2456.883693] mlx5_core 0000:82:00.0: mlx5_cmd_check:756:(pid 5273): SET_FLOW_TABLE_ENTRY(0x936) op_mod(0x0) failed, status bad parameter(0x3), syndrome (0xa9c090)
Use the correct enum value MLX5_FLOW_CONTEXT_FLOW_SOURCE_UPLINK.

Fixes: bb204dcf39fe ("net/mlx5e: Determine source port properly for vlan push action")
Signed-off-by: Dmytro Linkin <dmitrolin@mellanox.com>
Reviewed-by: Vlad Buslov <vladbu@mellanox.com>
Reviewed-by: Roi Dayan <roid@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
---
 .../net/ethernet/mellanox/mlx5/core/eswitch_offloads_termtbl.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads_termtbl.c b/drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads_termtbl.c
index 7879e1746297..366bda1bb1c3 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads_termtbl.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/eswitch_offloads_termtbl.c
@@ -183,7 +183,8 @@ static bool mlx5_eswitch_offload_is_uplink_port(const struct mlx5_eswitch *esw,
 	u32 port_mask, port_value;
 
 	if (MLX5_CAP_ESW_FLOWTABLE(esw->dev, flow_source))
-		return spec->flow_context.flow_source == MLX5_VPORT_UPLINK;
+		return spec->flow_context.flow_source ==
+					MLX5_FLOW_CONTEXT_FLOW_SOURCE_UPLINK;
 
 	port_mask = MLX5_GET(fte_match_param, spec->match_criteria,
 			     misc_parameters.source_port);
-- 
2.21.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

* Re: [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06
  2019-11-06 22:05 [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 Saeed Mahameed
                   ` (3 preceding siblings ...)
  2019-11-06 22:05 ` [net 4/4] net/mlx5e: Use correct enum to determine uplink port Saeed Mahameed
@ 2019-11-07  5:40 ` David Miller
  4 siblings, 0 replies; 6+ messages in thread
From: David Miller @ 2019-11-07  5:40 UTC (permalink / raw)
  To: saeedm; +Cc: netdev

From: Saeed Mahameed <saeedm@mellanox.com>
Date: Wed, 6 Nov 2019 22:05:38 +0000

> This series introduces some fixes to mlx5 driver.
> 
> Please pull and let me know if there is any problem.

Pulled, thanks.

> No -stable this time.

Phew :)

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2019-11-07  5:40 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-06 22:05 [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 Saeed Mahameed
2019-11-06 22:05 ` [net 1/4] net/mlx5e: Fix eswitch debug print of max fdb flow Saeed Mahameed
2019-11-06 22:05 ` [net 2/4] net/mlx5: DR, Fix memory leak in modify action destroy Saeed Mahameed
2019-11-06 22:05 ` [net 3/4] net/mlx5: DR, Fix memory leak during rule creation Saeed Mahameed
2019-11-06 22:05 ` [net 4/4] net/mlx5e: Use correct enum to determine uplink port Saeed Mahameed
2019-11-07  5:40 ` [pull request][net 0/4] Mellanox, mlx5 fixes 2019-11-06 David Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.