netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Saeed Mahameed <saeed@kernel.org>
To: "David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>
Cc: netdev@vger.kernel.org, Avihai Horon <avihaih@nvidia.com>,
	Saeed Mahameed <saeedm@nvidia.com>
Subject: [net 09/12] net/mlx5: Fix flow counters SF bulk query len
Date: Tue, 16 Nov 2021 12:23:18 -0800	[thread overview]
Message-ID: <20211116202321.283874-10-saeed@kernel.org> (raw)
In-Reply-To: <20211116202321.283874-1-saeed@kernel.org>

From: Avihai Horon <avihaih@nvidia.com>

When doing a flow counters bulk query, the number of counters to query
must be aligned to 4. Current SF bulk query len is not aligned to 4,
which leads to an error when trying to query more than 4 counters.

Fix it by aligning SF bulk query len to 4.

Fixes: 2fdeb4f4c2ae ("net/mlx5: Reduce flow counters bulk query buffer size for SFs")
Signed-off-by: Avihai Horon <avihaih@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
---
 drivers/net/ethernet/mellanox/mlx5/core/fs_counters.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/fs_counters.c b/drivers/net/ethernet/mellanox/mlx5/core/fs_counters.c
index 31c99d53faf7..7e0e04cf26f8 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/fs_counters.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/fs_counters.c
@@ -40,7 +40,7 @@
 #define MLX5_FC_STATS_PERIOD msecs_to_jiffies(1000)
 /* Max number of counters to query in bulk read is 32K */
 #define MLX5_SW_MAX_COUNTERS_BULK BIT(15)
-#define MLX5_SF_NUM_COUNTERS_BULK 6
+#define MLX5_SF_NUM_COUNTERS_BULK 8
 #define MLX5_FC_POOL_MAX_THRESHOLD BIT(18)
 #define MLX5_FC_POOL_USED_BUFF_RATIO 10
 
-- 
2.31.1


  parent reply	other threads:[~2021-11-16 20:23 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-16 20:23 [pull request][net 00/12] mlx5 fixes 2021-11-16 Saeed Mahameed
2021-11-16 20:23 ` [net 01/12] net/mlx5e: kTLS, Fix crash in RX resync flow Saeed Mahameed
2021-11-17 11:10   ` patchwork-bot+netdevbpf
2021-11-16 20:23 ` [net 02/12] net/mlx5e: Wait for concurrent flow deletion during neigh/fib events Saeed Mahameed
2021-11-16 20:23 ` [net 03/12] net/mlx5: E-Switch, Fix resetting of encap mode when entering switchdev Saeed Mahameed
2021-11-16 20:23 ` [net 04/12] net/mlx5e: nullify cq->dbg pointer in mlx5_debug_cq_remove() Saeed Mahameed
2021-11-16 20:23 ` [net 05/12] net/mlx5: DR, Handle eswitch manager and uplink vports separately Saeed Mahameed
2021-11-16 20:23 ` [net 06/12] net/mlx5: DR, Fix check for unsupported fields in match param Saeed Mahameed
2021-11-16 20:23 ` [net 07/12] net/mlx5: Update error handler for UCTX and UMEM Saeed Mahameed
2021-11-16 20:23 ` [net 08/12] net/mlx5: E-Switch, rebuild lag only when needed Saeed Mahameed
2021-11-16 20:23 ` Saeed Mahameed [this message]
2021-11-16 20:23 ` [net 10/12] net/mlx5e: CT, Fix multiple allocations and memleak of mod acts Saeed Mahameed
2021-11-16 20:23 ` [net 11/12] net/mlx5: Lag, update tracker when state change event received Saeed Mahameed
2021-11-16 20:23 ` [net 12/12] net/mlx5: E-Switch, return error if encap isn't supported Saeed Mahameed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211116202321.283874-10-saeed@kernel.org \
    --to=saeed@kernel.org \
    --cc=avihaih@nvidia.com \
    --cc=davem@davemloft.net \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=saeedm@nvidia.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).