From: Breno Leitao <leitao@debian.org>
To: Tony Nguyen <anthony.l.nguyen@intel.com>,
Przemek Kitszel <przemyslaw.kitszel@intel.com>,
Andrew Lunn <andrew+netdev@lunn.ch>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@kernel.org>,
Jakub Kicinski <kuba@kernel.org>,
Paolo Abeni <pabeni@redhat.com>,
Madhu Chittim <madhu.chittim@intel.com>,
Emil Tantilov <emil.s.tantilov@intel.com>,
Joshua Hay <joshua.a.hay@intel.com>,
Alan Brady <alan.brady@intel.com>,
Sridhar Samudrala <sridhar.samudrala@intel.com>,
Willem de Bruijn <willemb@google.com>,
Shailendra Bhatnagar <shailendra.bhatnagar@intel.com>,
Pavan Kumar Linga <pavan.kumar.linga@intel.com>
Cc: Phani Burra <phani.r.burra@intel.com>,
intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org, kernel-team@meta.com,
Breno Leitao <leitao@debian.org>
Subject: [PATCH net] idpf: reset mb_wait_count once the mailbox is up
Date: Mon, 09 Nov 2026 06:43:27 -0800 [thread overview]
Message-ID: <20261109-idpf-mb-wait-count-v1-1-c6584754df78@debian.org> (raw)
idpf_vc_core_init() retries a failed virtchnl version and capabilities
handshake up to IDPF_MB_MAX_ERR times before it gives up on the device.
Each failure increments adapter->mb_wait_count, but nothing ever clears
it, so the limit is shared by every initialization in the lifetime of
the adapter, including the one done by each reset.
A device that fails the first handshake after a reset, and then
recovers on the retry, leaves one count behind per reset. Once 20 have
accumulated, the next failure is final, and the device stays down until
the driver is reloaded. This is seen in Meta's fleet on hosts with
recurring Tx timeouts:
[ 2176.496801] idpf 0016:01:00.0 eth1: Detected Tx timeout: Count 21, Queue 11
[ 2176.508763] idpf 0016:01:00.0: Device HW Reset initiated
[ 2237.412541] idpf 0016:01:00.0: Transaction timed-out (op:1 cookie:9800 vc_op:1 salt:98 timeout:60000ms)
[ 2237.412578] idpf 0016:01:00.0: Failed to establish mailbox communications with hardware
Clear mb_wait_count once the handshake succeeds, so the limit applies
to consecutive failures only.
Fixes: 4930fbf419a7 ("idpf: add core init and interrupt request")
Signed-off-by: Breno Leitao <leitao@debian.org>
---
drivers/net/ethernet/intel/idpf/idpf_virtchnl.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/net/ethernet/intel/idpf/idpf_virtchnl.c b/drivers/net/ethernet/intel/idpf/idpf_virtchnl.c
index 928de868fa624e..7c11c877acd0ba 100644
--- a/drivers/net/ethernet/intel/idpf/idpf_virtchnl.c
+++ b/drivers/net/ethernet/intel/idpf/idpf_virtchnl.c
@@ -3118,6 +3118,9 @@ int idpf_vc_core_init(struct idpf_adapter *adapter)
msleep(task_delay);
}
+ /* The mailbox is up, give the next reset a fresh retry budget */
+ adapter->mb_wait_count = 0;
+
if (idpf_is_cap_ena(adapter, IDPF_OTHER_CAPS, VIRTCHNL2_CAP_LAN_MEMORY_REGIONS)) {
err = idpf_cfg_lan_memory_regions(adapter);
if (err) {
---
base-commit: 1d5e2c57e9ffc134e14b3f837c8d7c53b508bd22
change-id: 20261109-idpf-mb-wait-count-184efb41b525
Best regards,
--
Breno Leitao <leitao@debian.org>
reply other threads:[~2026-11-09 14:43 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20261109-idpf-mb-wait-count-v1-1-c6584754df78@debian.org \
--to=leitao@debian.org \
--cc=alan.brady@intel.com \
--cc=andrew+netdev@lunn.ch \
--cc=anthony.l.nguyen@intel.com \
--cc=davem@davemloft.net \
--cc=edumazet@kernel.org \
--cc=emil.s.tantilov@intel.com \
--cc=intel-wired-lan@lists.osuosl.org \
--cc=joshua.a.hay@intel.com \
--cc=kernel-team@meta.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=madhu.chittim@intel.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=pavan.kumar.linga@intel.com \
--cc=phani.r.burra@intel.com \
--cc=przemyslaw.kitszel@intel.com \
--cc=shailendra.bhatnagar@intel.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
all inboxes | Powered by JetHome®