netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net] mlxsw: spectrum: Fix IP2ME CPU policer configuration
@ 2018-11-02 19:49 Ido Schimmel
  2018-11-04  2:32 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: Ido Schimmel @ 2018-11-02 19:49 UTC (permalink / raw)
  To: netdev@vger.kernel.org
  Cc: davem@davemloft.net, Jiri Pirko, Shalom Toledo, mlxsw,
	Ido Schimmel

From: Shalom Toledo <shalomt@mellanox.com>

The CPU policer used to police packets being trapped via a local route
(IP2ME) was incorrectly configured to police based on bytes per second
instead of packets per second.

Change the policer to police based on packets per second and avoid
packet loss under certain circumstances.

Fixes: 9148e7cf73ce ("mlxsw: spectrum: Add policers for trap groups")
Signed-off-by: Shalom Toledo <shalomt@mellanox.com>
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
---
 drivers/net/ethernet/mellanox/mlxsw/spectrum.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/net/ethernet/mellanox/mlxsw/spectrum.c b/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
index a2df12b79f8e..9bec940330a4 100644
--- a/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
+++ b/drivers/net/ethernet/mellanox/mlxsw/spectrum.c
@@ -3568,7 +3568,6 @@ static int mlxsw_sp_cpu_policers_set(struct mlxsw_core *mlxsw_core)
 			burst_size = 7;
 			break;
 		case MLXSW_REG_HTGT_TRAP_GROUP_SP_IP2ME:
-			is_bytes = true;
 			rate = 4 * 1024;
 			burst_size = 4;
 			break;
-- 
2.17.2

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

* Re: [PATCH net] mlxsw: spectrum: Fix IP2ME CPU policer configuration
  2018-11-02 19:49 [PATCH net] mlxsw: spectrum: Fix IP2ME CPU policer configuration Ido Schimmel
@ 2018-11-04  2:32 ` David Miller
  0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2018-11-04  2:32 UTC (permalink / raw)
  To: idosch; +Cc: netdev, jiri, shalomt, mlxsw

From: Ido Schimmel <idosch@mellanox.com>
Date: Fri, 2 Nov 2018 19:49:15 +0000

> From: Shalom Toledo <shalomt@mellanox.com>
> 
> The CPU policer used to police packets being trapped via a local route
> (IP2ME) was incorrectly configured to police based on bytes per second
> instead of packets per second.
> 
> Change the policer to police based on packets per second and avoid
> packet loss under certain circumstances.
> 
> Fixes: 9148e7cf73ce ("mlxsw: spectrum: Add policers for trap groups")
> Signed-off-by: Shalom Toledo <shalomt@mellanox.com>
> Signed-off-by: Ido Schimmel <idosch@mellanox.com>

Applied and queued up for -stable, thank you.

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

end of thread, other threads:[~2018-11-04 11:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-11-02 19:49 [PATCH net] mlxsw: spectrum: Fix IP2ME CPU policer configuration Ido Schimmel
2018-11-04  2:32 ` David Miller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).