public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Tony Nguyen <anthony.l.nguyen@intel.com>
To: davem@davemloft.net, kuba@kernel.org, pabeni@redhat.com,
	edumazet@google.com, andrew+netdev@lunn.ch,
	netdev@vger.kernel.org
Cc: Li Li <boolli@google.com>,
	anthony.l.nguyen@intel.com, emil.s.tantilov@intel.com,
	sridhar.samudrala@intel.com, joshua.a.hay@intel.com,
	brianvv@google.com, decot@google.com, willemb@google.com,
	Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Subject: [PATCH net 01/13] idpf: increment completion queue next_to_clean in sw marker wait routine
Date: Thu, 19 Feb 2026 16:40:13 -0800	[thread overview]
Message-ID: <20260220004027.729384-2-anthony.l.nguyen@intel.com> (raw)
In-Reply-To: <20260220004027.729384-1-anthony.l.nguyen@intel.com>

From: Li Li <boolli@google.com>

Currently, in idpf_wait_for_sw_marker_completion(), when an
IDPF_TXD_COMPLT_SW_MARKER packet is found, the routine breaks out of
the for loop and does not increment the next_to_clean counter. This
causes the subsequent NAPI polls to run into the same
IDPF_TXD_COMPLT_SW_MARKER packet again and print out the following:

    [   23.261341] idpf 0000:05:00.0 eth1: Unknown TX completion type: 5

Instead, we should increment next_to_clean regardless when an
IDPF_TXD_COMPLT_SW_MARKER packet is found.

Tested: with the patch applied, we do not see the errors above from NAPI
polls anymore.

Fixes: 9d39447051a0 ("idpf: remove SW marker handling from NAPI")
Signed-off-by: Li Li <boolli@google.com>
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
---
 drivers/net/ethernet/intel/idpf/idpf_txrx.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/ethernet/intel/idpf/idpf_txrx.c b/drivers/net/ethernet/intel/idpf/idpf_txrx.c
index 376050308b06..761a77510467 100644
--- a/drivers/net/ethernet/intel/idpf/idpf_txrx.c
+++ b/drivers/net/ethernet/intel/idpf/idpf_txrx.c
@@ -2348,7 +2348,7 @@ void idpf_wait_for_sw_marker_completion(const struct idpf_tx_queue *txq)
 
 	do {
 		struct idpf_splitq_4b_tx_compl_desc *tx_desc;
-		struct idpf_tx_queue *target;
+		struct idpf_tx_queue *target = NULL;
 		u32 ctype_gen, id;
 
 		tx_desc = flow ? &complq->comp[ntc].common :
@@ -2368,14 +2368,14 @@ void idpf_wait_for_sw_marker_completion(const struct idpf_tx_queue *txq)
 		target = complq->txq_grp->txqs[id];
 
 		idpf_queue_clear(SW_MARKER, target);
-		if (target == txq)
-			break;
 
 next:
 		if (unlikely(++ntc == complq->desc_count)) {
 			ntc = 0;
 			gen_flag = !gen_flag;
 		}
+		if (target == txq)
+			break;
 	} while (time_before(jiffies, timeout));
 
 	idpf_queue_assign(GEN_CHK, complq, gen_flag);
-- 
2.47.1


  reply	other threads:[~2026-02-20  0:40 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-20  0:40 [PATCH net 00/13][pull request] Intel Wired LAN Driver Updates 2026-02-19 (idpf, ice, i40e, ixgbevf, e1000e) Tony Nguyen
2026-02-20  0:40 ` Tony Nguyen [this message]
2026-02-20  0:40 ` [PATCH net 02/13] idpf: skip deallocating bufq_sets from rx_qgrp if it is NULL Tony Nguyen
2026-02-20  0:40 ` [PATCH net 03/13] idpf: skip deallocating txq group's txqs " Tony Nguyen
2026-02-20  0:40 ` [PATCH net 04/13] idpf: nullify pointers after they are freed Tony Nguyen
2026-02-20  0:40 ` [PATCH net 05/13] idpf: change IRQ naming to match netdev and ethtool queue numbering Tony Nguyen
2026-02-20  0:40 ` [PATCH net 06/13] idpf: Fix flow rule delete failure due to invalid validation Tony Nguyen
2026-02-20  0:40 ` [PATCH net 07/13] ice: recap the VSI and QoS info after rebuild Tony Nguyen
2026-02-20  0:40 ` [PATCH net 08/13] ice: fix crash in ethtool offline loopback test Tony Nguyen
2026-02-20  0:40 ` [PATCH net 09/13] i40e: Fix preempt count leak in napi poll tracepoint Tony Nguyen
2026-02-20  0:40 ` [PATCH net 10/13] ixgbevf: fix link setup issue Tony Nguyen
2026-02-20  0:40 ` [PATCH net 11/13] e1000e: introduce new board type for Panther Lake PCH Tony Nguyen
2026-02-20  0:40 ` [PATCH net 12/13] e1000e: clear DPG_EN after reset to avoid autonomous power-gating Tony Nguyen
2026-02-20  0:40 ` [PATCH net 13/13] e1000e: correct TIMINCA on ADP/TGP systems with wrong XTAL frequency Tony Nguyen
2026-02-22 16:28   ` [net,13/13] " Simon Horman
2026-02-24 22:59     ` Tony Nguyen
2026-02-25  0:11       ` Jakub Kicinski
2026-02-25 18:42         ` Tony Nguyen

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=20260220004027.729384-2-anthony.l.nguyen@intel.com \
    --to=anthony.l.nguyen@intel.com \
    --cc=aleksandr.loktionov@intel.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=boolli@google.com \
    --cc=brianvv@google.com \
    --cc=davem@davemloft.net \
    --cc=decot@google.com \
    --cc=edumazet@google.com \
    --cc=emil.s.tantilov@intel.com \
    --cc=joshua.a.hay@intel.com \
    --cc=kuba@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=sridhar.samudrala@intel.com \
    --cc=willemb@google.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