DPDK-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Cheryl Bansal <cheryl.bansal@altera.com>
To: dev@dpdk.org
Cc: Cheryl Bansal <cheryl.bansal@altera.com>
Subject: [PATCH 08/12] net/mlx5: fix minsize build
Date: Mon, 30 Nov 2026 14:01:39 +0530	[thread overview]
Message-ID: <20261130083143.1629652-9-cheryl.bansal@altera.com> (raw)
In-Reply-To: <20261130083143.1629652-1-cheryl.bansal@altera.com>

This error is seen in build of type "minsize":

drivers/net/mlx5/mlx5_flow_hw.c:13656:38: error:
'age_idx' may be used uninitialized [-Werror=maybe-uninitialized]

It looks to be a compiler issue because we stop the loop
if rte_ring_dequeue_elem() fails, before using age_idx.

The variable is initialized to allow compiling with "minsize" option.

Fixes: 04a4de756e14 ("net/mlx5: support flow age action with HWS")

Signed-off-by: Cheryl Bansal <cheryl.bansal@altera.com>
---
 drivers/net/mlx5/mlx5_flow_hw.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c
index 6e6bf07799..6da09bc5eb 100644
--- a/drivers/net/mlx5/mlx5_flow_hw.c
+++ b/drivers/net/mlx5/mlx5_flow_hw.c
@@ -13648,7 +13648,7 @@ flow_hw_get_q_aged_flows(struct rte_eth_dev *dev, uint32_t queue_id,
 	if (nb_contexts == 0)
 		return rte_ring_count(r);
 	while ((uint32_t)nb_flows < nb_contexts) {
-		uint32_t age_idx;
+		uint32_t age_idx = 0;
 
 		if (rte_ring_dequeue_elem(r, &age_idx, sizeof(uint32_t)) < 0)
 			break;
-- 
2.43.0


  parent reply	other threads:[~2026-11-30  8:33 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-30  8:31 [PATCH 00/12] fix minsize build Cheryl Bansal
2026-11-30  8:31 ` [PATCH 01/12] member: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 02/12] mempool/bucket: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 03/12] dma/skeleton: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 04/12] dma/dpaa: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 05/12] net/softnic: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 06/12] net/nfp: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 07/12] net/pcap: " Cheryl Bansal
2026-11-30  8:31 ` Cheryl Bansal [this message]
2026-11-30  8:31 ` [PATCH 09/12] crypto/mlx5: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 10/12] crypto/ccp: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 11/12] common/cnxk: " Cheryl Bansal
2026-11-30  8:31 ` [PATCH 12/12] test/bonding: " Cheryl Bansal
2026-11-30 18:03 ` [PATCH 00/12] " Stephen Hemminger

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=20261130083143.1629652-9-cheryl.bansal@altera.com \
    --to=cheryl.bansal@altera.com \
    --cc=dev@dpdk.org \
    /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