From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id DC809606A31A for ; Wed, 2 Dec 2026 17:19:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20260707 header.b=m0aOOTp6 Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id CE44340609; Wed, 2 Dec 2026 18:19:24 +0100 (CET) Received: from mail-dl1-f46.google.com (mail-dl1-f46.google.com [74.125.82.46]) by mails.dpdk.org (Postfix) with ESMTPS id C9685402D5 for ; Wed, 2 Dec 2026 18:19:23 +0100 (CET) Received: by mail-dl1-f46.google.com with SMTP id a92af1059eb24-1b546061d58so6329576c88.1 for ; Wed, 02 Dec 2026 09:19:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20260707; t=1796231962; x=1796836762; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to:content-type; bh=rlEqhcoBK0eQxPFVN3smU60oFffvgrzpyKSLZBiV2Bs=; b=m0aOOTp6C+cg2+orGqIWiDLW3NPpHStGpUZD4SxvmwWo4PM1fIr9bAYCelJzHKYijd mgQ2Re76js25mKvbnO1ZdelW1Lppins5DK+IksX5nT4zQEvr0/0Qgog2yCdbfgOq312U lyEBPMpnoTypmpjdHPITnH8SGZmsMYs6FVODElaHlHgjMaXmlUfrhtJdGW0540AG+FOr 5G0VAzE0lxHAMyix/Wc/u4QBptCIMAmM2JF11op8N9KibWESa+TassY4h41K61yuMPKO K7OqgZ0SfN47WTtvRov7yrBG7KPXf1zl4snoq7pt1HU2Hcg7zqLPsYLw1k6FRLpoKbNk KPJA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20260707; t=1796231962; x=1796836762; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=rlEqhcoBK0eQxPFVN3smU60oFffvgrzpyKSLZBiV2Bs=; b=GuOjdpG80uaC15SQ0EjPIBoZ26YBBwtlTu/L9pOmlucYjd2ObZCb7U7oNwqLnbb+f9 otm9LOIWrxQQHHCdiMWZBHh6KQu7bwg0ldbae2dXGPqzJkod3lDON0KNdNF3kPL8gN2k Z4J2EAuwZMqNKE/SyuZSqP2KseE/KSuTDL2SPnecbS+9/GD6sFHnDSXYU9w1QlzcDEzI Zvxm2HcqgwAqn0LkcgG6VtKXMmNwt59U+jzdHQeA8veiIeRYJS7RZt5VudF7l6dvh2aE HmbyFEDJOds4YfWB0mjO2oJzngRnV6nNVTVoHwDCX4LgtFP2q0/oOAFcVdGM4a/UQqPD t0jA== X-Gm-Message-State: APuU4Z/lMb/klOBZbdwnuL0x2AOCFnF28E4qsEcaw0VMtyeeqJ4o6Wm1 SOlOBck3lcN/CZeYFzp8f6REWp9y8paGENir4FU7WHr7Ucx1w77hlcL6fDf0Cw== X-Gm-Gg: AZFdTZeW4D2u1lgYZ38VISae/QBqPHD4R56ZpCAJX3KlKXzbptYI9M7M2l7H37DP3M+ adeheeH6TWfizv9blHcl7yl51K8QMC4JFta4xeXt9KNL9u3rug9wyDApUOuobzeM0yp3Fakatpu zK0p0q0JWag1xfvX2kQBHdWCf11zCFz4ZuchLpQATg820vX+ngqb+AxNvOH6NCtmjMlokeeaheC ZAPNj6P0KVUWhQq92z8ceHI3qoXHJGbz4fOcaWjX5AdHol0K9zJrV2Im7zx2Pv00C2AmBAp4MTH ez3sBgRYUbbrKqv/hE8weoA688gU6nRbnkviZzoS/MBwrj02UO+QaFtjoKEj9ceiTBF9WxMC8IN gt2gAOTyOLKL7rk8FBGPilACxglnmpU882o29016Iq00Taw/OvKTUZcGvZytSpzN9xQ68hpUpMn 3kzTq/KOFUDPIA9eeQh6X6rEiLB2D9XGnUZ96j0piEfmJMpNDokudSiU3vqKsm14Try7u2ErJS9 Zeykkc79kuRnNO9o7yhPLLEeGP0I9UCQjt08eZPx3cKtbE7ZCK0pfg2AOUU9r4nwADoGpNyti7n aSMFLqekb/c7SSmILY1DH4+VWCv2pgDwustrrvsT8Rw8mKf9PLiggV34AnRTRgyV9uuSvn+crQ= = X-Received: by 2002:a05:7022:e80a:b0:1b3:b8a2:825d with SMTP id a92af1059eb24-1b5567f681emr46547575c88.3.1796231961756; Wed, 02 Dec 2026 09:19:21 -0800 (PST) Received: from mr41p01nt-relayp04.apple.com ([17.199.97.123]) by smtp.gmail.com with ESMTPSA id a92af1059eb24-1b55682d301sm97449533c88.10.2026.12.02.09.19.20 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Wed, 02 Dec 2026 09:19:21 -0800 (PST) From: Scott Mitchell To: dev@dpdk.org Cc: stephen@networkplumber.org, thomas@monjalon.net, david.marchand@redhat.com, mb@smartsharesystems.com, Scott Mitchell Subject: [PATCH v8 0/8] net/af_packet fixes and Tx features Date: Wed, 2 Dec 2026 09:17:56 -0800 Message-ID: <20261202171804.50287-1-scott.k.mitch1@gmail.com> X-Mailer: git-send-email 2.54.0 In-Reply-To: <20261201222405.88922-1-scott.k.mitch1@gmail.com> References: <20261201222405.88922-1-scott.k.mitch1@gmail.com> X-Archived-By: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Archive: List-Post: List-Help: List-Subscribe: , X-Spam-Status: No, score=-10.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 Fixes for af_packet ring handling, then Tx features: non-blocking Tx and software checksum offload. Patches 1-3 are fixes for stable, and 4 tests them. 5-8 are not for stable. v8: * Split as suggested: the memory ordering and frame address fixes are separate stable patches; the test, ring parameter validation and Tx cleanup are their own patches. Dropped unrelated changes from the fixes (counter types, loop form). * tp_status uses rte_atomic_load/store_explicit with acquire/release instead of fences, as libpcap and memif do. (Stephen) * New fix: the maximum Rx packet length and MTU used the Tx frame offset, so packets up to 34 bytes over the real limit were silently truncated. * Invalid ring parameters are rejected at probe, matching what packet_set_ring() rejects, instead of logged as warnings; the hint warnings are gone, so configurations the kernel accepts still work. (Stephen) * The Tx kick runs on every burst, so a full ring drains on later bursts once the kernel can send again. The ring full test now checks this. (Stephen) * Removed poll() from Tx instead of adding the txpollnotrdy devarg. A full ring returns a short count, so Tx no longer blocks. (Stephen) * Checksums are computed in the ring frame after the copy, so the checksum code does not modify the mbuf. Dropped rte_net_ip_udptcp_cksum_mbuf() and the tap conversion, and with them the dependency on "test/cksum: fix EtherType of IPv6 TCP packet". (Stephen, Morten) IPv6 extension headers are supported; packets with tunnel offload flags are dropped. * Tests use ring geometry derived from the page size. Scott Mitchell (8): net/af_packet: fix frame status memory ordering net/af_packet: fix frame address with unused block tail net/af_packet: fix maximum Rx packet length test/af_packet: add frame layout tests net/af_packet: reject invalid ring parameters at probe net/af_packet: clean up Tx and bulk free mbufs net/af_packet: do not block in Tx when the ring is full net/af_packet: add Tx checksum offload app/test/test_pmd_af_packet.c | 1029 +++++++++++++++++++++ doc/guides/nics/af_packet.rst | 8 +- doc/guides/nics/features/af_packet.ini | 2 + doc/guides/rel_notes/release_27_03.rst | 4 + drivers/net/af_packet/rte_eth_af_packet.c | 245 +++-- 5 files changed, 1212 insertions(+), 76 deletions(-) -- 2.54.0 (Apple Git-157)