From nobody Fri Aug 7 14:35:34 2026 X-Original-To: dev-commits-src-main@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 4hGmsL6jfJz6nBqb for ; Fri, 07 Aug 2026 14:35:34 +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 4hGmsL611Zz3Wnb for ; Fri, 07 Aug 2026 14:35:34 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1786113334; 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=0hwdI8nvK8f3Uv1KRrROjy1nhFuoPjiJ48PMhxWY1Ps=; b=OeWwY1K1dF+HxohSnNhoz6kQylR2f0oggbAeOAMpDoYXw7YvzbxyRCwhe4xPDN5QPle11A 8RvHvWSkYmH/Nc9R3coydf5ZNt69b7xrKHFVULdzqqeMiCXRagchR6Q4X+LcBQ72eBFf0m 0GK9FMRhOT0dq/mFIoWGqISH+Ak/qe0Tobk9//Q3QZIFoB2yVLxcj3T9cCKTNJV+rz3sth tw6JkPfUYqHE0OcABAiLym2K7vMu/S66+x5FswXBbviOOs5sNlo7kRTIMnXj3vsVesICa+ Q4qBZf9JlalXD3vfA/jJXIbDz1j5vbGE3MnU1CXYC9Zm7nH2mAdC6Nv0CqE02Q== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1786113334; a=rsa-sha256; cv=none; b=W+fgNests2BOBppB4+pW4tBBtKR2caK/UISZg2pN8DyGfu8LTEqF7ME8lZI56CmjH5vBnD tt4EnCnAHcG4EODtXI33Dacja+ODBiaiap/Y9vUWTSMGMXeB217bBPG1WuZ9dNKSuf696P gMwtSjKLrijyEHIOwYwB5l2EmNRGGRak2l7IkiZDLYjIeCLrn21bP4gk3XnQDD3HcQuzRr r1JdGZ9BzIuUf84SSi5K5gIn12vFLhdxsVPDa1BO0P9STEVEZGoHvZOr4h1SopPHeUEthw TlQIEh/JZAiBW2PQEfysb51UkvV93VZcvpJyId8+MlCugbR8c3kS96A33RLaGA== 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=1786113334; 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=0hwdI8nvK8f3Uv1KRrROjy1nhFuoPjiJ48PMhxWY1Ps=; b=mlLM+47g4oOcGw6uPoaHQis/vgh0xlLgtLaW0gjxocn797Ce9SAXN+fcuN0H2GBQEtT7wI tkDbdbRmImXsOx1R6GIu9rhe5/+E0yFqKwrezl2Bsm+RcqmWlqICwF6rJ5qO+oKexFg1fJ K9P8SE2cLDIx7RlgoLvFALTEu70nPMEE1DkD+11mxDUTSMc3ZjUq/ULRnyYX539ar2GUR6 L0lm9gEu5Y90yu64MPOWIHz74PEaHzTHDKKQK+NvxjUBwqxs0yBUDV3QM8CW3Ze0Ep7mpr uM4tKLD8QESiz3GDF38xhl+j4YPl+6qVgmpX0nYk2Vz7vkRR/C/KJmooLVVB4A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hGmsL4yszz1B6D for ; Fri, 07 Aug 2026 14:35:34 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 45a1d by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Fri, 07 Aug 2026 14:35:34 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Kevin Bowling Subject: git: 2a803e6f349c - main - ixgbe: Use PF MTU for 82599 VF jumbo policy List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@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: 2a803e6f349c3d6cf770089f8a71bc5139308465 Auto-Submitted: auto-generated Date: Fri, 07 Aug 2026 14:35:34 +0000 Message-Id: <6a75ed36.45a1d.f1d997d@gitrepo.freebsd.org> The branch main has been updated by kbowling: URL: https://cgit.FreeBSD.org/src/commit/?id=2a803e6f349c3d6cf770089f8a71bc5139308465 commit 2a803e6f349c3d6cf770089f8a71bc5139308465 Author: Kevin Bowling AuthorDate: 2026-08-05 14:14:44 +0000 Commit: Kevin Bowling CommitDate: 2026-08-07 14:29:42 +0000 ixgbe: Use PF MTU for 82599 VF jumbo policy The shared maximum frame size is raised by VF LPE requests, so it cannot describe the PF MTU when enforcing the 82599 PF/VF jumbo restriction. Consult the PF ifnet MTU instead. Also correct the API 1.1 and later comparison so a jumbo VF is enabled when, and only when, the PF itself uses a jumbo MTU. This matches the policy implemented by DPDK. MFC after: 2 weeks --- sys/dev/ixgbe/if_sriov.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/sys/dev/ixgbe/if_sriov.c b/sys/dev/ixgbe/if_sriov.c index 32b4935e3b44..af0027a073c8 100644 --- a/sys/dev/ixgbe/if_sriov.c +++ b/sys/dev/ixgbe/if_sriov.c @@ -491,6 +491,9 @@ ixgbe_vf_clear_mac_filters(struct ixgbe_softc *sc, struct ixgbe_vf *vf, static boolean_t ixgbe_vf_frame_size_compatible(struct ixgbe_softc *sc, struct ixgbe_vf *vf) { + if_t ifp; + bool pf_jumbo; + /* * Frame size compatibility between PF and VF is only a problem on * 82599-based cards. X540 and later support any combination of jumbo @@ -499,6 +502,10 @@ ixgbe_vf_frame_size_compatible(struct ixgbe_softc *sc, struct ixgbe_vf *vf) if (sc->hw.mac.type != ixgbe_mac_82599EB) return (true); + /* sc->max_frame_size includes VF requests; use the PF's actual MTU. */ + ifp = iflib_get_ifp(sc->ctx); + pf_jumbo = if_getmtu(ifp) > ETHERMTU; + switch (vf->api_ver) { case IXGBE_API_VER_1_0: case IXGBE_API_VER_UNKNOWN: @@ -506,8 +513,7 @@ ixgbe_vf_frame_size_compatible(struct ixgbe_softc *sc, struct ixgbe_vf *vf) * On legacy (1.0 and older) VF versions, we don't support * jumbo frames on either the PF or the VF. */ - if (sc->max_frame_size > ETHER_MAX_LEN || - vf->maximum_frame_size > ETHER_MAX_LEN) + if (pf_jumbo || vf->maximum_frame_size > ETHER_MAX_LEN) return (false); return (true); @@ -526,10 +532,7 @@ ixgbe_vf_frame_size_compatible(struct ixgbe_softc *sc, struct ixgbe_vf *vf) * Jumbo frames only work with VFs if the PF is also using * jumbo frames. */ - if (sc->max_frame_size <= ETHER_MAX_LEN) - return (true); - - return (false); + return (pf_jumbo); } } /* ixgbe_vf_frame_size_compatible */