From: Vincent Jardin <vjardin@free.fr>
To: dev@dpdk.org
Cc: rasland@nvidia.com, thomas@monjalon.net,
andrew.rybchenko@oktetlabs.ru, dsosnowski@nvidia.com,
viacheslavo@nvidia.com, bingz@nvidia.com, orika@nvidia.com,
suanmingm@nvidia.com, matan@nvidia.com,
Vincent Jardin <vjardin@free.fr>
Subject: [PATCH v1 02/10] common/mlx5: query packet pacing rate table capabilities
Date: Tue, 10 Mar 2026 10:20:06 +0100 [thread overview]
Message-ID: <20260310092014.2762894-3-vjardin@free.fr> (raw)
In-Reply-To: <20260310092014.2762894-1-vjardin@free.fr>
Query additional QoS packet pacing capabilities from HCA attributes:
- packet_pacing_burst_bound: HW supports burst_upper_bound parameter
- packet_pacing_typical_size: HW supports typical_packet_size parameter
- packet_pacing_max_rate / packet_pacing_min_rate: rate range in kbps
- packet_pacing_rate_table_size: number of HW rate table entries
These capabilities are needed by the upcoming per-queue rate limiting
feature to validate devarg values and report HW limits.
Supported hardware:
- ConnectX-6 Dx and later (different boards expose different subsets)
- ConnectX-5 reports packet_pacing but not all extended fields
- ConnectX-7/8 report the full capability set
- BlueField-2 and later DPUs also report these capabilities
Not supported:
- ConnectX-4 Lx and earlier (no packet_pacing capability at all)
- ConnectX-5 Ex may not report burst_bound or typical_size
Signed-off-by: Vincent Jardin <vjardin@free.fr>
---
drivers/common/mlx5/mlx5_devx_cmds.c | 15 +++++++++++++++
drivers/common/mlx5/mlx5_devx_cmds.h | 11 ++++++++++-
2 files changed, 25 insertions(+), 1 deletion(-)
diff --git a/drivers/common/mlx5/mlx5_devx_cmds.c b/drivers/common/mlx5/mlx5_devx_cmds.c
index d12ebf8487..8f53303fa7 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.c
+++ b/drivers/common/mlx5/mlx5_devx_cmds.c
@@ -1244,6 +1244,21 @@ mlx5_devx_cmd_query_hca_attr(void *ctx,
MLX5_GET(qos_cap, hcattr, packet_pacing);
attr->qos.wqe_rate_pp =
MLX5_GET(qos_cap, hcattr, wqe_rate_pp);
+ attr->qos.packet_pacing_burst_bound =
+ MLX5_GET(qos_cap, hcattr,
+ packet_pacing_burst_bound);
+ attr->qos.packet_pacing_typical_size =
+ MLX5_GET(qos_cap, hcattr,
+ packet_pacing_typical_size);
+ attr->qos.packet_pacing_max_rate =
+ MLX5_GET(qos_cap, hcattr,
+ packet_pacing_max_rate);
+ attr->qos.packet_pacing_min_rate =
+ MLX5_GET(qos_cap, hcattr,
+ packet_pacing_min_rate);
+ attr->qos.packet_pacing_rate_table_size =
+ MLX5_GET(qos_cap, hcattr,
+ packet_pacing_rate_table_size);
if (attr->qos.flow_meter_aso_sup) {
attr->qos.log_meter_aso_granularity =
MLX5_GET(qos_cap, hcattr,
diff --git a/drivers/common/mlx5/mlx5_devx_cmds.h b/drivers/common/mlx5/mlx5_devx_cmds.h
index da50fc686c..930ae2c072 100644
--- a/drivers/common/mlx5/mlx5_devx_cmds.h
+++ b/drivers/common/mlx5/mlx5_devx_cmds.h
@@ -67,7 +67,16 @@ struct mlx5_hca_qos_attr {
/* Power of the maximum allocation granularity Object. */
uint32_t log_max_num_meter_aso:5;
/* Power of the maximum number of supported objects. */
-
+ uint32_t packet_pacing_burst_bound:1;
+ /* HW supports burst_upper_bound PP parameter. */
+ uint32_t packet_pacing_typical_size:1;
+ /* HW supports typical_packet_size PP parameter. */
+ uint32_t packet_pacing_max_rate;
+ /* Maximum supported pacing rate in kbps. */
+ uint32_t packet_pacing_min_rate;
+ /* Minimum supported pacing rate in kbps. */
+ uint16_t packet_pacing_rate_table_size;
+ /* Number of entries in the HW rate table. */
};
struct mlx5_hca_vdpa_attr {
--
2.43.0
next prev parent reply other threads:[~2026-03-10 9:21 UTC|newest]
Thread overview: 88+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-10 9:20 [PATCH v1 00/10] net/mlx5: per-queue Tx rate limiting via packet pacing Vincent Jardin
2026-03-10 9:20 ` [PATCH v1 01/10] doc/nics/mlx5: fix stale packet pacing documentation Vincent Jardin
2026-03-11 12:26 ` Slava Ovsiienko
2026-03-10 9:20 ` Vincent Jardin [this message]
2026-03-10 9:20 ` [PATCH v1 03/10] common/mlx5: extend SQ modify to support rate limit update Vincent Jardin
2026-03-10 9:20 ` [PATCH v1 04/10] net/mlx5: add per-queue packet pacing infrastructure Vincent Jardin
2026-03-10 9:20 ` [PATCH v1 05/10] net/mlx5: support per-queue rate limiting Vincent Jardin
2026-03-10 9:20 ` [PATCH v1 06/10] net/mlx5: add burst pacing devargs Vincent Jardin
2026-03-10 9:20 ` [PATCH v1 07/10] net/mlx5: add testpmd command to query per-queue rate limit Vincent Jardin
2026-03-10 9:20 ` [PATCH v1 08/10] ethdev: add getter for per-queue Tx " Vincent Jardin
2026-03-10 9:20 ` [PATCH v1 9/10] net/mlx5: share pacing rate table entries across queues Vincent Jardin
2026-03-10 9:20 ` [PATCH v1 10/10] net/mlx5: add rate table capacity query API Vincent Jardin
2026-03-10 14:20 ` [PATCH v1 00/10] net/mlx5: per-queue Tx rate limiting via packet pacing Stephen Hemminger
2026-03-10 23:26 ` [PATCH v2 " Vincent Jardin
2026-03-10 23:26 ` [PATCH v2 01/10] doc/nics/mlx5: fix stale packet pacing documentation Vincent Jardin
2026-03-10 23:26 ` [PATCH v2 02/10] common/mlx5: query packet pacing rate table capabilities Vincent Jardin
2026-03-10 23:26 ` [PATCH v2 03/10] common/mlx5: extend SQ modify to support rate limit update Vincent Jardin
2026-03-10 23:26 ` [PATCH v2 04/10] net/mlx5: add per-queue packet pacing infrastructure Vincent Jardin
2026-03-11 16:29 ` Stephen Hemminger
2026-03-10 23:26 ` [PATCH v2 05/10] net/mlx5: support per-queue rate limiting Vincent Jardin
2026-03-10 23:26 ` [PATCH v2 06/10] net/mlx5: add burst pacing devargs Vincent Jardin
2026-03-10 23:26 ` [PATCH v2 07/10] net/mlx5: add testpmd command to query per-queue rate limit Vincent Jardin
2026-03-11 16:31 ` Stephen Hemminger
2026-03-10 23:26 ` [PATCH v2 08/10] ethdev: add getter for per-queue Tx " Vincent Jardin
2026-03-11 16:17 ` Stephen Hemminger
2026-03-11 16:26 ` Stephen Hemminger
2026-03-12 15:54 ` Vincent Jardin
2026-03-10 23:26 ` [PATCH v2 09/10] net/mlx5: share pacing rate table entries across queues Vincent Jardin
2026-03-10 23:26 ` [PATCH v2 10/10] net/mlx5: add rate table capacity query API Vincent Jardin
2026-03-11 16:31 ` Stephen Hemminger
2026-03-11 16:35 ` Stephen Hemminger
2026-03-12 15:05 ` Vincent Jardin
2026-03-12 16:01 ` Stephen Hemminger
2026-03-12 22:01 ` [PATCH v3 00/9] net/mlx5: per-queue Tx rate limiting via packet pacing Vincent Jardin
2026-03-12 22:01 ` [PATCH v3 01/9] doc/nics/mlx5: fix stale packet pacing documentation Vincent Jardin
2026-03-12 22:01 ` [PATCH v3 02/9] common/mlx5: query packet pacing rate table capabilities Vincent Jardin
2026-03-20 12:02 ` Slava Ovsiienko
2026-03-12 22:01 ` [PATCH v3 03/9] common/mlx5: extend SQ modify to support rate limit update Vincent Jardin
2026-03-20 12:01 ` Slava Ovsiienko
2026-03-12 22:01 ` [PATCH v3 04/9] net/mlx5: add per-queue packet pacing infrastructure Vincent Jardin
2026-03-20 12:51 ` Slava Ovsiienko
2026-03-12 22:01 ` [PATCH v3 05/9] net/mlx5: support per-queue rate limiting Vincent Jardin
2026-03-20 15:11 ` Slava Ovsiienko
2026-03-12 22:01 ` [PATCH v3 06/9] net/mlx5: add burst pacing devargs Vincent Jardin
2026-03-20 15:19 ` Slava Ovsiienko
2026-03-12 22:01 ` [PATCH v3 07/9] net/mlx5: add testpmd command to query per-queue rate limit Vincent Jardin
2026-03-20 15:38 ` Slava Ovsiienko
2026-03-22 14:02 ` Vincent Jardin
2026-03-12 22:01 ` [PATCH v3 08/9] ethdev: add getter for per-queue Tx " Vincent Jardin
2026-03-20 15:44 ` Slava Ovsiienko
2026-03-12 22:01 ` [PATCH v3 09/9] net/mlx5: add rate table capacity query API Vincent Jardin
2026-03-20 15:49 ` Slava Ovsiienko
2026-03-16 16:04 ` [PATCH v3 00/9] net/mlx5: per-queue Tx rate limiting via packet pacing Stephen Hemminger
2026-03-22 14:16 ` Vincent Jardin
2026-03-22 13:46 ` [PATCH v4 00/10] " Vincent Jardin
2026-03-22 13:46 ` [PATCH v4 01/10] doc/nics/mlx5: fix stale packet pacing documentation Vincent Jardin
2026-03-22 13:46 ` [PATCH v4 02/10] common/mlx5: query packet pacing rate table capabilities Vincent Jardin
2026-03-22 13:46 ` [PATCH v4 03/10] common/mlx5: extend SQ modify to support rate limit update Vincent Jardin
2026-03-23 12:59 ` Slava Ovsiienko
2026-03-22 13:46 ` [PATCH v4 04/10] net/mlx5: add per-queue packet pacing infrastructure Vincent Jardin
2026-03-23 13:00 ` Slava Ovsiienko
2026-03-22 13:46 ` [PATCH v4 05/10] net/mlx5: support per-queue rate limiting Vincent Jardin
2026-03-23 13:17 ` Slava Ovsiienko
2026-03-22 13:46 ` [PATCH v4 06/10] net/mlx5: add burst pacing devargs Vincent Jardin
2026-03-23 13:18 ` Slava Ovsiienko
2026-03-22 13:46 ` [PATCH v4 07/10] net/mlx5: add testpmd command to query per-queue rate limit Vincent Jardin
2026-03-23 13:19 ` Slava Ovsiienko
2026-03-22 13:46 ` [PATCH v4 08/10] ethdev: add getter for per-queue Tx " Vincent Jardin
2026-03-23 13:19 ` Slava Ovsiienko
2026-03-22 13:46 ` [PATCH v4 09/10] net/mlx5: implement per-queue Tx rate limit getter Vincent Jardin
2026-03-23 13:20 ` Slava Ovsiienko
2026-03-22 13:46 ` [PATCH v4 10/10] net/mlx5: add rate table capacity query API Vincent Jardin
2026-03-23 13:20 ` Slava Ovsiienko
2026-03-23 23:09 ` [PATCH v4 00/10] net/mlx5: per-queue Tx rate limiting via packet pacing Stephen Hemminger
2026-03-24 16:50 ` [PATCH v5 " Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 01/10] doc/nics/mlx5: fix stale packet pacing documentation Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 02/10] common/mlx5: query packet pacing rate table capabilities Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 03/10] common/mlx5: extend SQ modify to support rate limit update Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 04/10] net/mlx5: add per-queue packet pacing infrastructure Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 05/10] net/mlx5: support per-queue rate limiting Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 06/10] net/mlx5: add burst pacing devargs Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 07/10] net/mlx5: add testpmd command to query per-queue rate limit Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 08/10] ethdev: add getter for per-queue Tx " Vincent Jardin
2026-03-25 2:24 ` Stephen Hemminger
2026-03-24 16:50 ` [PATCH v5 09/10] net/mlx5: implement per-queue Tx rate limit getter Vincent Jardin
2026-03-24 16:50 ` [PATCH v5 10/10] net/mlx5: add rate table capacity query API Vincent Jardin
2026-03-25 2:25 ` [PATCH v5 00/10] net/mlx5: per-queue Tx rate limiting via packet pacing Stephen Hemminger
2026-04-13 13:18 ` Raslan Darawsheh
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=20260310092014.2762894-3-vjardin@free.fr \
--to=vjardin@free.fr \
--cc=andrew.rybchenko@oktetlabs.ru \
--cc=bingz@nvidia.com \
--cc=dev@dpdk.org \
--cc=dsosnowski@nvidia.com \
--cc=matan@nvidia.com \
--cc=orika@nvidia.com \
--cc=rasland@nvidia.com \
--cc=suanmingm@nvidia.com \
--cc=thomas@monjalon.net \
--cc=viacheslavo@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