From nobody Fri Jul 31 12:14:50 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 4hBQ4J44vdz6mfq6 for ; Fri, 31 Jul 2026 12:14:56 +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 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "YR1" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4hBQ4J1s3Dz3KnR for ; Fri, 31 Jul 2026 12:14:56 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1785500096; 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=nrkoZYBDhINdJ1/Umghh7g5tgUGpxiXTfreP3+2SAiI=; b=LavWSrLaLlkoPI2MLuoUG8sUsexARG5tb5kDQwKy1MnYq/vso4hFdH8AeBsbKyre5ylt1I eNzpIabF1nlTH9U3n6+9FwMma/qAeqS4CnwgrpLymqvy5kHAhFOFRrTWFWIuTql0I54ldS iwiZbCoI14UcLEF/kJ1F5kK8Bo13P/QyROrkBnplHouI1Djk6RECeYlU16w7Q6TpPUz0M2 5e4znowlo4yBnQhB6eImnUQiyF37syQHLgdPXar/MSzoHTZSPeVX0THoEBoWOQS9AFxlRc r5YPnkX5bBHHBf0IKeWdOSkErtNKNPHFVVXu5nFPW8rm2epXkQ/kSQq1ZsUzKg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1785500096; a=rsa-sha256; cv=none; b=cctvYG3DrSrHhpzhV9T45xkIjzzmDXaWCW9H6BA5pRzvfOZZZx5tDF/quwXrTX4hFPtAxw pQjsjZ93ga4U24E/0eYXgp6ubqL9uTo00L17iTB0EZlShmG8hjwD6T3sqiVP4DONi/5LH+ gV0Tx3ybMpuDOU1jFoIfg9vpIMyEYiVy5Nfvr6jpYuyXaQmHsGQpBIq3PCx64yVigC8/HT x9yeixYTGwEx+6v9jeAxeTNIRMHllS8WN0tOTT7VKZmTil8sOUOhtdJGKaN7HPINj1k3rO sNh6K5SLm4sE4bG/z4osR/W40noMgzRd80MumwzgbH9EoqYAsjaRHUx9SsWlhg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1785500096; 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=nrkoZYBDhINdJ1/Umghh7g5tgUGpxiXTfreP3+2SAiI=; b=FO7kzOwNjpW7WvfpJ8K8f2iXpOX645S+cKcU0U1W+67ydSqxUCDR5EawWffvIomCoZSJHf 0v76RpADVgAD1igVTr6srpfWhUyZ3Z3bobQLJXCYgZUlGxAG0Js1dU3hUm1a334y0YF4dX zpr5tc9VaBI8BMMakJy2JSNCHbStzdLVbYAnQ5+TDQu3byEkkJZKnYnQB59SZ2J3n4kHry T6Mf7PpTqjlr2RUMxzCi1Gc7gTwDSu/fen3pZPEsMpQQxLYvO7vX3witMSE63Rb+LhnsG2 fgW0r1XQKMp9zTSoQbm5kQcXNLZs1fiL44QiykUNe9a76UGKYa6df2L1UFWJiA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hBQ4J0Jjtzygt for ; Fri, 31 Jul 2026 12:14:56 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 41b3e by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 31 Jul 2026 12:14:50 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kevin Bowling Subject: git: 6f940ca879cb - main - ixgbe: clear VF head write-back state on reset List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org List-Id: 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: kbowling X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 6f940ca879cbf691ddf5605d852770cef27847b2 Auto-Submitted: auto-generated Date: Fri, 31 Jul 2026 12:14:50 +0000 Message-Id: <6a6c91ba.41b3e.8cb1b7f@gitrepo.freebsd.org> The branch main has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=6f940ca879cbf691ddf5605d852770cef27847b2 commit 6f940ca879cbf691ddf5605d852770cef27847b2 Author: Kevin Bowling AuthorDate: 2026-07-28 11:26:28 +0000 Commit: Kevin Bowling CommitDate: 2026-07-31 12:14:36 +0000 ixgbe: clear VF head write-back state on reset VF reset and FLR do not clear the transmit head write-back address registers. A previous VF driver can therefore leave DMA write-back enabled with a stale address for the next driver instance. After consuming the reset request and disabling the VF queues, clear the address registers for each queue belonging to that VF. Derive the queue count from the active IOV mode so peer queue state is not touched. Linux commit dbf231af81a7 documents the hardware behavior. The FreeBSD implementation follows the local queue mapping and register interfaces. MFC after: 1 week --- sys/dev/ixgbe/if_sriov.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/sys/dev/ixgbe/if_sriov.c b/sys/dev/ixgbe/if_sriov.c index 8d4e20fcf8bf..b9e5205cf1b9 100644 --- a/sys/dev/ixgbe/if_sriov.c +++ b/sys/dev/ixgbe/if_sriov.c @@ -353,6 +353,7 @@ ixgbe_vf_reset_msg(struct ixgbe_softc *sc, struct ixgbe_vf *vf, uint32_t *msg) struct ixgbe_hw *hw; uint32_t ack; uint32_t resp[IXGBE_VF_PERMADDR_MSG_LEN]; + int i, queue_count; hw = &sc->hw; @@ -363,6 +364,18 @@ ixgbe_vf_reset_msg(struct ixgbe_softc *sc, struct ixgbe_vf *vf, uint32_t *msg) */ ixgbe_clear_mbx(hw, vf->pool); + /* + * VF reset does not clear the transmit head write-back addresses. + * The queues were disabled by ixgbe_process_vf_reset(). + */ + queue_count = ixgbe_vf_queues(sc->iov_mode); + for (i = 0; i < queue_count; i++) { + IXGBE_WRITE_REG(hw, + IXGBE_PVFTDWBAHn(queue_count, vf->pool, i), 0); + IXGBE_WRITE_REG(hw, + IXGBE_PVFTDWBALn(queue_count, vf->pool, i), 0); + } + if (ixgbe_validate_mac_addr(vf->ether_addr) == 0) { ixgbe_set_rar(&sc->hw, vf->rar_index, vf->ether_addr, vf->pool, true);