From nobody Mon Aug 24 07:27:00 2026 X-Original-To: dev-commits-src-branches@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 4hT2Y103Y1z6X8rg for ; Mon, 24 Aug 2026 07:27:01 +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 "YR2" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 4hT2Y067yjz3h3P for ; Mon, 24 Aug 2026 07:27:00 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1787556420; 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=9lOhfvu4Z8KgOb1QHGsgvwEvbVrGs53K9wkCg0Scoyo=; b=MGPRiGLYvFT5IQZmlOros/kdKVwGldsmu9H6KOz4p0aqILD9ZII7Fr+DhddZTMUPGv0DCm bJHMxPFJsQQkJrLMhTx6MnHOyL5HaSB85CazVkrJ8L+h7EW0PcyDHKezWZfEQRGIAIO94O 5E8Y9KvkR1MvbX1nzaY22qWgZUAPrzno2gydgoefwEyYMwTNDELnlpGL38jt9/lWnwGDWo M++80Wu6juh49EsscWOwJa6sbkCgzgkhApEA3NqFS0PGI5NS2fEuSyxq5lGBGUAd8pfBX3 P/dottAXpKVft1UkswDStYffsyEU3MKxlxWihECdOmD5rodQ72mSPIJkKojPbA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1787556420; a=rsa-sha256; cv=none; b=V7vhzisYfX+wV8eRXNs+deIzfmoXDRLfp1SkBNyzHKQMyegEOSP+v7lfWt3XihS8TlIlwG HRDcecwhFJhDCAxFbwRhODsA7xXXn5ntg1zCKl9pWVDPLihkkB9y8nffqQfcv8F48t4at+ 3clzz6F4luEWtgkVnEcgLSmiZSga4Y6HwiF/WBkjESuGW8hbnQO2m4vqJLI9uufJYxm4oM MHLD/BjGXAW71YiyGFD6t4D5kZyWLzWrTkgwM58YTPuyIl7XC5ofglzPeMsFYpbnOUZ4Bn m6+SGwkWHfhv7taY3Ug9TE9Gsj6VgGIwEElMZ39bbMDChWpUGas29Z012aNZog== 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=1787556420; 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=9lOhfvu4Z8KgOb1QHGsgvwEvbVrGs53K9wkCg0Scoyo=; b=nhff1jknJLh5cTyHLBhd8gFjqmBqHlFrPHeWV2KZ4qwk53c6+hr3NIZi06uoXm/XGHQDV1 tXc6bfxVnBVHYXACjvKKt27Qr7efJM7vNNPjhciGSr1eSgVrxUJVDi0BdGdbn+TNR7AY8e y5g3PwB7i2CbukRRxqLZO7XhDVselFLWliqcdemQllzSIapfxHjzuvtSgaDbw7cy7DMB1X ZVnbzXWtYKboNjk+XgyAfryuhxaxd6BM3AIQYLAxZfB9o73ouGlqMu0yka9Wez6IQU/RZ5 od+GYCCvQWtPQCX+c0XRmkWAaLHSO8Ps9zDnSVHcwYwnCq0wD56gh3b2HjhzSw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) by mxrelay.nyi.freebsd.org (Postfix) with ESMTP id 4hT2Y055GJzvY3 for ; Mon, 24 Aug 2026 07:27:00 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from git (uid 1279) (envelope-from git@FreeBSD.org) id 3e02f by gitrepo.freebsd.org (DragonFly Mail Agent v0.13+ on gitrepo.freebsd.org); Mon, 24 Aug 2026 07:27:00 +0000 To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Kristof Provost Subject: git: b92d13ab60dc - stable/14 - pfsync: handle large MTU pfsync interfaces List-Id: Commits to the stable branches of the FreeBSD src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-branches List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-branches@freebsd.org Sender: owner-dev-commits-src-branches@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: kp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: b92d13ab60dc0eb929e66edddf6f389e5b56e50d Auto-Submitted: auto-generated Date: Mon, 24 Aug 2026 07:27:00 +0000 Message-Id: <6a8bf244.3e02f.1c9409dc@gitrepo.freebsd.org> The branch stable/14 has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=b92d13ab60dc0eb929e66edddf6f389e5b56e50d commit b92d13ab60dc0eb929e66edddf6f389e5b56e50d Author: Kristof Provost AuthorDate: 2026-08-07 14:07:09 +0000 Commit: Kristof Provost CommitDate: 2026-08-24 07:17:33 +0000 pfsync: handle large MTU pfsync interfaces pfsync packets were allocated with m_get2(), which can't return packets larger than MJUMPAGESIZE. As a result 9k MTU pfsync interfaces simply didn't work. Use m_get3(), which can allocate sufficiently large mbufs. Extend the pfsync:bulk test case to provoke this problem. PR: 297307 MFC after: 2 weeks Sponsored by: Rubicon Communications, LLC ("Netgate") (cherry picked from commit 7e2781fdcfdbe489cc07572d33dc36bca06a342d) --- sys/netpfil/pf/if_pfsync.c | 2 +- tests/sys/netpfil/pf/pfsync.sh | 11 ++++++++--- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/sys/netpfil/pf/if_pfsync.c b/sys/netpfil/pf/if_pfsync.c index 4d83962abc74..1868bf35fa76 100644 --- a/sys/netpfil/pf/if_pfsync.c +++ b/sys/netpfil/pf/if_pfsync.c @@ -1830,7 +1830,7 @@ pfsync_sendout(int schedswi, int c) return; } - m = m_get2(max_linkhdr + b->b_len, M_NOWAIT, MT_DATA, M_PKTHDR); + m = m_get3(max_linkhdr + b->b_len, M_NOWAIT, MT_DATA, M_PKTHDR); if (m == NULL) { if_inc_counter(sc->sc_ifp, IFCOUNTER_OERRORS, 1); V_pfsyncstats.pfsyncs_onomem++; diff --git a/tests/sys/netpfil/pf/pfsync.sh b/tests/sys/netpfil/pf/pfsync.sh index 01d76e23889c..b87621204ff7 100644 --- a/tests/sys/netpfil/pf/pfsync.sh +++ b/tests/sys/netpfil/pf/pfsync.sh @@ -203,13 +203,14 @@ bulk_body() # pfsync interface jexec one ifconfig ${epair_sync}a 192.0.2.1/24 up + jexec one ifconfig ${epair_sync}a mtu 9000 jexec one ifconfig ${epair_one}a 198.51.100.1/24 up jexec one ifconfig pfsync0 \ syncdev ${epair_sync}a \ - maxupd 1\ - up + up mtu 9000 jexec two ifconfig ${epair_two}a 198.51.100.2/24 up jexec two ifconfig ${epair_sync}b 192.0.2.2/24 up + jexec two ifconfig ${epair_sync}b mtu 9000 # Enable pf jexec one pfctl -e @@ -223,7 +224,11 @@ bulk_body() ifconfig ${epair_one}b 198.51.100.254/24 up - # Create state prior to setting up pfsync + # Create states prior to setting up pfsync + ${common_dir}/pft_synflood.py \ + --sendif ${epair_one}b \ + --to 198.51.100.1 \ + --count 2500 ping -c 1 -S 198.51.100.254 198.51.100.1 # Wait before setting up pfsync on two, so we don't accidentally catch