From nobody Mon Nov 23 14:30:53 2026 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4jY7f56hsGz6w5CT for ; Mon, 23 Nov 2026 14:30:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 4jY7f5481fz4hbW for ; Mon, 23 Nov 2026 14:30:53 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1795444253; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=j7cMBE+XAkYlnN7yK0u/Y6tQmJSBp0mlR3GApLLgoWo=; b=CUZbYqxp9+PO9CyTQCE+yXDzKW01H5SJGZpZ7WtUljaL5SPA2ntovBricoI7h4CrMrk4ls +VDWC0cBnxCfrYZT+N96JAnyWqIFhdHO5YePAWqMNDVOHVcltDQN4B5mGrC4gW9c+ud7v2 kfnE2m90DglQ66E67Yzdv8V3vF5zsdb86RQzQL4LrA6I2heyS/Vn47UcOSFLN6yw45lmUs aD1LfmnSTBakLj2mJj4jauZ6kXTq5hidvmwNBaeSc0VdLkL//PBw4FxqQBCXeSVnZ8ytnv 4zqN82wBn4UBr7qjCwaYJAW6OhtDZRR3W/hVszxthrl3t0u+jzwWzrud9+HEUg== ARC-Seal: i=1; a=rsa-sha256; d=freebsd.org; s=dkim; cv=none; t=1795444253; b=qzQmne8e6Vd2I+QEcyyr7UxpDZ8N4VPtW1iNsirCH3K4mVmg1JyHYRhdG40uVNHcPuGg4B te9vKkJbdJa8+rMaJpkrX5PztFU7Ywl7G2nof8C6oIoLxWYxETNR8vOQVXup2Q7GYBvw/G RQZAyrAsrYq1ip43P55KVS0XD16X3Oh3hSaBZZGb5FWEm4MM+NyIkKsdFXAGZdiw3myf9P K4sE29w6j7Ng8X3mb/pPbJO7HDdGBv/90FAd87/juLJpOUbuZr+wc+OEOiPkuSZcPxFYyf gvL6yu2ap55NX7ni5zjOsOZkR1QoQk7LJBAJ6ql3yr2PVgMDy/P3GqFG2sztGg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1795444253; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=j7cMBE+XAkYlnN7yK0u/Y6tQmJSBp0mlR3GApLLgoWo=; b=kPLZP4FMt7kDX+/W5kt9X/emcsbEL3BwYMPzN9EI4bKz9O0U1yUlVm+cYp0gI2OqBmY7ts w2l2VTjabpkOz0556c2bJ7iRSX0H+e/CJYMy6xxP0zTCc0coKZDg4B16WYxGh/GO7AADkK e4v6ykHVqUZP3nH3KvHOchH3qtcgD/kkNeyRwdrzEGni70pI+tU086Jagb+QAuZtLIR4HO 8fBVOl6/Aaek/GLhiSuTdP6jDDXZmlQTO9E7U0iIPhI9SXFtFJ7wJwk7lFa1JHwXd9oURU mm2NKxje/Ji/C7KOLk9p+uF3llEn0BzLdLHmNMfe2l581iWnzGz1Pmxivf4n/g== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4jY7f53kNmzv21 for ; Mon, 23 Nov 2026 14:30:53 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id e621 by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 23 Nov 2026 14:30:53 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: R. Christian McDonald Subject: git: 927151737725 - main - ixl/iavf: Start the head write-back completion index at the head List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all X-BeenThere: dev-commits-src-all@freebsd.org List-Id: Commit messages for all branches of the src repository List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: rcm X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 927151737725e88b050bfcae17f8a38448869aa8 Auto-Submitted: auto-generated Date: Mon, 23 Nov 2026 14:30:53 +0000 Message-Id: <6b044e1d.e621.458a0406@gitrepo.freebsd.org> The branch main has been updated by rcm: URL: https://cgit.FreeBSD.org/src/commit/?id=927151737725e88b050bfcae17f8a38448869aa8 commit 927151737725e88b050bfcae17f8a38448869aa8 Author: R. Christian McDonald AuthorDate: 2026-11-23 14:29:06 +0000 Commit: R. Christian McDonald CommitDate: 2026-11-23 14:30:48 +0000 ixl/iavf: Start the head write-back completion index at the head With head write-back, tx_cidx_processed holds the head value that the credits update consumed last: the index of the next descriptor to complete. With the Report Status queue it is the index of the last completed descriptor. 088a0b27adb4 made both start at the last descriptor of the ring, which is right for the Report Status queue only. With head write-back, the default in ixl(4), the first credits update after every initialization reports a completed descriptor that was never sent. iflib's own reclaim holds back isc_tx_nsegments descriptors and does not notice. netmap uses the count as it is: iflib_netmap_txsync() puts the tail of its ring one slot too far. Once the card has sent everything, the tail meets the head, which netmap reads as a ring without a free slot, and no completion is left that would move it. The ring never transmits again: pkt-gen at full rate stops after a few thousand packets, and a ring that one pkt-gen has used cannot be used by the next. The workaround has been hw.ixl.enable_head_writeback=0. Start at the head of the cleared ring, as before that change. iavf(4) has a copy of the code and gets the same change. PR: 255671 Reviewed by: kgalazka Fixes: 088a0b27adb4 ("intel iflib drivers: correct...") MFC after: 1 week Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D61715 --- sys/dev/iavf/if_iavf_iflib.c | 4 ++-- sys/dev/ixl/ixl_txrx.c | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/sys/dev/iavf/if_iavf_iflib.c b/sys/dev/iavf/if_iavf_iflib.c index 4f908a8d9a7b..e9be44046175 100644 --- a/sys/dev/iavf/if_iavf_iflib.c +++ b/sys/dev/iavf/if_iavf_iflib.c @@ -2539,14 +2539,14 @@ iavf_init_tx_rsqs(struct iavf_vsi *vsi) void iavf_init_tx_cidx(struct iavf_vsi *vsi) { - if_softc_ctx_t scctx = vsi->shared; struct iavf_tx_queue *tx_que; int i; for (i = 0, tx_que = vsi->tx_queues; i < vsi->num_tx_queues; i++, tx_que++) { struct tx_ring *txr = &tx_que->txr; - txr->tx_cidx_processed = scctx->isc_ntxd[0] - 1; + /* Next descriptor to complete (the head), not the last one. */ + txr->tx_cidx_processed = 0; } } diff --git a/sys/dev/ixl/ixl_txrx.c b/sys/dev/ixl/ixl_txrx.c index 7ce1c24c814a..bd4f46b1e62a 100644 --- a/sys/dev/ixl/ixl_txrx.c +++ b/sys/dev/ixl/ixl_txrx.c @@ -795,14 +795,14 @@ ixl_init_tx_rsqs(struct ixl_vsi *vsi) void ixl_init_tx_cidx(struct ixl_vsi *vsi) { - if_softc_ctx_t scctx = vsi->shared; struct ixl_tx_queue *tx_que; int i; - + for (i = 0, tx_que = vsi->tx_queues; i < vsi->num_tx_queues; i++, tx_que++) { struct tx_ring *txr = &tx_que->txr; - txr->tx_cidx_processed = scctx->isc_ntxd[0] - 1; + /* Next descriptor to complete (the head), not the last one. */ + txr->tx_cidx_processed = 0; } }