| Message ID | cover.1790843153.git.ralf@mandelbit.com |
|---|---|
| Headers |
Return-Path: <openvpn-devel-bounces@lists.sourceforge.net>
Delivered-To: patchwork@openvpn.net
Received: by 2002:a05:7000:6ac1:b0:8b3:6e77:b38b with SMTP id v1csp1809918maw;
Thu, 1 Oct 2026 01:43:42 -0700 (PDT)
X-Forwarded-Encrypted: i=2;
AKwUvBzvBtzTXprnsZ+FqLWzZ8w31VoYh9JeZh67fY2sY2Al3iBEYHWPzXH/mjdsvHKcyPb6UM8XskjShGE=@openvpn.net
X-Received: by 2002:a05:6808:180c:b0:4d6:92b3:5c83 with SMTP id
5614622812f47-4f1b8d9681bmr4883313b6e.64.1790844118626;
Thu, 01 Oct 2026 01:41:58 -0700 (PDT)
ARC-Seal: i=1; a=rsa-sha256; t=1790844118; cv=none;
d=google.com; s=arc-20260327;
b=sKA9CeKUPiKSk8ynAf27FXSPhvi+YUfse7GkdfGXm7vAlxpy967vBAv+bseKBpZsgb
0MbuXEiQ219UyllOW+ftUiPFF0HbSQmSKOjS/CLo093DiUB04//NMhVdNNEVs+TB0y0j
0NSDwchysvyIimggHvOgamY7/nDioFDTX8YpeXV6ksOFlQeFsu7ZFbnYsL+zYXjuHSod
q4yzFqwu71o6dwjo2ChvI0SUBRXEOs3pVio4ZbfzVfQIlBQAekB5hsYPpowFfPKBZ/rU
s/VM/nzU8v8O11SNU2SktQbSqs7HgvCX3iyM8exNNiQ7eo/Yz+0D2yfO4SQjX/QVe4Yr
tvuA==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com;
s=arc-20260327;
h=errors-to:content-transfer-encoding:list-subscribe:list-help
:list-post:list-archive:list-unsubscribe:list-id:precedence:subject
:mime-version:message-id:date:to:from:dkim-signature:dkim-signature
:dkim-signature:dkim-signature;
bh=LWtK3Jg1FDgm8JiaKDokgVkgXjGY3WKQ0Wq7lVOdtyw=;
fh=4NbAC/LsuMLI0S0hprUlLSLCiHwg6SCAifhH718Jh0Q=;
b=CixrHJ7S2wlVTIJNkxfE6NwwZxYF0a6INoByIV1p8geS0hLirtZQAr9sMXngodj7p2
iDF1drhs8RDJRvcFYCaZf4QruUYNv4e+wFOPRv6enuVkVDMps0w2BmHWYPUVCFwvlBga
oE41ZLU7M0QTeyatwZebfMPKpjyLgnRARsBT7MmM+qWq0wdrl19y8OUk1YoSKhEU1o4M
lNFasDBzdhI7+o/g6BA6hh0svaK7PK0YPAkpwB7wH0YOBXc95A7mas+cxUGNTq2ypSOU
Ylm2ZKEboKeb1p6lc5gyB9jzcv1ulvgkiBmq2xQ+uvlECLOV2PBya9gvkgtWJmaRtUtj
QKBg==;
dara=google.com
ARC-Authentication-Results: i=1; mx.google.com;
dkim=pass header.i=@lists.sourceforge.net header.s=beta
header.b=fLbfuQFV;
dkim=neutral (body hash did not verify) header.i=@sourceforge.net
header.s=x header.b="jCRR/Hsj";
dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x
header.b="NT/ccQn5";
dkim=neutral (body hash did not verify) header.i=@mandelbit.com
header.s=MBO0001 header.b=LGVqeQzp;
spf=pass (google.com: domain of
openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as
permitted sender) smtp.mailfrom=openvpn-devel-bounces@lists.sourceforge.net
Received: from lists.sourceforge.net (lists.sourceforge.net. [216.105.38.7])
by mx.google.com with ESMTPS id
5614622812f47-4f351e4b580si2987849b6e.71.2026.10.01.01.41.58
(version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128);
Thu, 01 Oct 2026 01:41:58 -0700 (PDT)
Received-SPF: pass (google.com: domain of
openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as
permitted sender) client-ip=216.105.38.7;
Authentication-Results: mx.google.com;
dkim=pass header.i=@lists.sourceforge.net header.s=beta
header.b=fLbfuQFV;
dkim=neutral (body hash did not verify) header.i=@sourceforge.net
header.s=x header.b="jCRR/Hsj";
dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x
header.b="NT/ccQn5";
dkim=neutral (body hash did not verify) header.i=@mandelbit.com
header.s=MBO0001 header.b=LGVqeQzp;
spf=pass (google.com: domain of
openvpn-devel-bounces@lists.sourceforge.net designates 216.105.38.7 as
permitted sender) smtp.mailfrom=openvpn-devel-bounces@lists.sourceforge.net
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=lists.sourceforge.net; s=beta; h=Content-Transfer-Encoding:Content-Type:
List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:
Subject:MIME-Version:Message-ID:Date:To:From:Sender:Reply-To:Cc:Content-ID:
Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc
:Resent-Message-ID:In-Reply-To:References:List-Owner;
bh=LWtK3Jg1FDgm8JiaKDokgVkgXjGY3WKQ0Wq7lVOdtyw=; b=fLbfuQFV05niuEXxoiwvhTWly/
NZseikf74OgpLsNMOhsRbRKyA9POL9RHgk/Cn/35eFJ02JaFtkiXVfvfJDZw5pT9+GzJ1SeB2DK4O
rQ4Z+FaOE7QytsgTkxkRgWTquh19uz+HwOacQ/FEvYkzCogy27Kkeis/MPrlN7GuaQj4=;
Received: from [127.0.0.1] (helo=sfs-ml-1.v29.lw.sourceforge.com)
by sfs-ml-1.v29.lw.sourceforge.com with esmtp (Exim 4.95)
(envelope-from <openvpn-devel-bounces@lists.sourceforge.net>)
id 1xCCMU-0003Vj-FT;
Thu, 01 Oct 2026 08:41:52 +0000
Received: from [172.30.29.66] (helo=mx.sourceforge.net)
by sfs-ml-1.v29.lw.sourceforge.com with esmtps (TLS1.2) tls
TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95)
(envelope-from <ralf@mandelbit.com>) id 1xCCMO-0003QZ-0W
for openvpn-devel@lists.sourceforge.net;
Thu, 01 Oct 2026 08:41:46 +0000
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=sourceforge.net; s=x; h=Content-Transfer-Encoding:MIME-Version:Message-ID:
Date:Subject:To:From:Sender:Reply-To:Cc:Content-Type:Content-ID:
Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc
:Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:
List-Subscribe:List-Post:List-Owner:List-Archive;
bh=WUtwPxoNl/vMCxlmb7PNbPeoTDqz1sHg0d/9wFNLa1U=; b=jCRR/HsjzpVS1/VzhJ2J4belYx
78NMoSkcVm3Q2ahu4w59J0s3hq0/xoCXgkqfbRDJDB5IDNZ/YhkqjQfYR8tOjInlHdmvW3fFwK9RA
C2Ebww6btlJE2BxkXYfblLhbv9n3MYIuTtdmxhX33JD7oWuFxuyqp+o0bq3WuaEoW0x8=;
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x
;
h=Content-Transfer-Encoding:MIME-Version:Message-ID:Date:Subject:To:From:
Sender:Reply-To:Cc:Content-Type:Content-ID:Content-Description:Resent-Date:
Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:
References:List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:
List-Owner:List-Archive; bh=WUtwPxoNl/vMCxlmb7PNbPeoTDqz1sHg0d/9wFNLa1U=; b=N
T/ccQn5gBgM1PWbC1/NK0z4AXQozL0JfxtFdI6z6vzomNOSwe22Yx8+kS8ihjGF3+eLKQKIybMYKt
iSg2rXdOvVdr4lIh3CtwUkCgkdTTAKRGBGEEDMoo+16yctfQCbsQW7b6ye9mGkG0ggKteSKeR40up
ccTDfDyncUVvBOB0=;
Received: from mout-b-110.mailbox.org ([195.10.208.55])
by sfi-mx-2.v28.lw.sourceforge.com with esmtps
(TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.95)
id 1xCCMJ-0003Tq-Ix for openvpn-devel@lists.sourceforge.net;
Thu, 01 Oct 2026 08:41:44 +0000
Received: from smtp102.mailbox.org (smtp102.mailbox.org [10.196.197.102])
(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 mout-b-110.mailbox.org (Postfix) with ESMTPS id 4hwQPW18vmzNlcB
for <openvpn-devel@lists.sourceforge.net>;
Thu, 01 Oct 2026 10:41:35 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mandelbit.com;
s=MBO0001; t=1790844095;
h=from:from:reply-to:subject:subject:date:date:message-id:message-id:
to:to:cc:mime-version:mime-version:
content-transfer-encoding:content-transfer-encoding;
bh=WUtwPxoNl/vMCxlmb7PNbPeoTDqz1sHg0d/9wFNLa1U=;
b=LGVqeQzpxKqrk/8+LK18G0O30IjKpKsIzx8VgZDosCfiF2FGenx73HTLMMUBmFmT1hBzBe
HpOurhxSnWQf75upi/BcKu0wv72pb2eOzMXX9ZAkjOgn+RkX2EUd6/40mzkMcjZSXGurKY
rBLgh9DW/UYvSTcivv79XiqZ7A9Aoc0ehCkGo9G54cJfqdbW61YMbcxxGjOPRYck520h9b
sxlHNRy3htdGxA/PZKoGaKYlpQbp3S/ryqHJuow7QzEtJLgxpvJzFfSxk1Sc5DP1+8k+OF
0JQTUsJciGTEQZmK8vdaCXxuKI6g8IO+c/huWR/J+m0vE5eeLVTuhDvud56Yhg==
From: Ralf Lici <ralf@mandelbit.com>
To: openvpn-devel@lists.sourceforge.net
Date: Thu, 1 Oct 2026 10:41:19 +0200
Message-ID: <cover.1790843153.git.ralf@mandelbit.com>
MIME-Version: 1.0
X-Spam-Score: -0.2 (/)
X-Spam-Report: Spam detection software,
running on the system "sfi-spamd-1.hosts.colo.sdot.me",
has NOT identified this incoming email as spam. The original
message has been attached to this so you can view it or label
similar future email. If you have any questions, see
the administrator of that system for details.
Content preview: Hi,
This series is a reworked version of my earlier RFC exploring
how ovpn can preserve GSO and GRO batching across its data path. Since
sending
the RFC, I spent more time profiling the paths on different [...]
Content analysis details: (-0.2 points, 5.0 required)
pts rule name description
---- ----------------------
--------------------------------------------------
0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2)
[195.10.208.55 listed in wl.mailspike.net]
-0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's
domain
-0.1 DKIM_VALID Message has at least one valid DKIM or DK signature
0.1 DKIM_SIGNED Message has a DKIM or DK signature,
not necessarily valid
-0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from
envelope-from domain
X-Headers-End: 1xCCMJ-0003Tq-Ix
Subject: [Openvpn-devel] [PATCH ovpn net-next 0/8] ovpn: preserve GSO and
GRO batching
X-BeenThere: openvpn-devel@lists.sourceforge.net
X-Mailman-Version: 2.1.21
Precedence: list
List-Id: <openvpn-devel.lists.sourceforge.net>
List-Unsubscribe: <https://lists.sourceforge.net/lists/options/openvpn-devel>,
<mailto:openvpn-devel-request@lists.sourceforge.net?subject=unsubscribe>
List-Archive:
<http://sourceforge.net/mailarchive/forum.php?forum_name=openvpn-devel>
List-Post: <mailto:openvpn-devel@lists.sourceforge.net>
List-Help: <mailto:openvpn-devel-request@lists.sourceforge.net?subject=help>
List-Subscribe: <https://lists.sourceforge.net/lists/listinfo/openvpn-devel>,
<mailto:openvpn-devel-request@lists.sourceforge.net?subject=subscribe>
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: 7bit
Errors-To: openvpn-devel-bounces@lists.sourceforge.net
X-getmail-retrieved-from-mailbox: Inbox
X-GMAIL-THRID: 1877836162815482281
X-GMAIL-MSGID: 1877836162815482281
|
| Series |
ovpn: preserve GSO and GRO batching
|
|
Message
Ralf Lici
Oct. 1, 2026, 8:41 a.m. UTC
Hi, This series is a reworked version of my earlier RFC exploring how ovpn can preserve GSO and GRO batching across its data path. Since sending the RFC, I spent more time profiling the paths on different systems and refining the implementation. The result is a smaller series with some additional optimizations and a fresh set of measurements. On transmit, it lets GSO skbs reach ovpn, completes each inner packet's checksum during software segmentation and, when the layout permits, encrypts the resulting packets directly into a UDP GSO aggregate. Ordinary packets and frag-list GSO children retain the existing in-place encryption path. Packet IDs for a UDP GSO batch are reserved as a single range instead of one segment at a time. On receive, ovpn uses UDP GRO to collect compatible DATA_V2 records in a frag-list, then detaches and authenticates each record independently. Small transmit and receive prefetch changes use the resulting lookahead to overlap memory access with encryption and decryption. On two directly connected 100-Gbit/s mlx5 ports, five interleaved iperf3 -t 60 -O 10 single-flow AES-128-GCM runs in each direction raised mean throughput from 12.053 to 24.166 Gbit/s forward and from 10.992 to 23.558 Gbit/s reverse. Individual patch messages contain the intermediate measurements and test details. Thanks, Ralf Lici Mandelbit Srl --- Changes since RFC v4 https://lore.kernel.org/openvpn-devel/cover.1789558856.git.ralf@mandelbit.com/ - Drop the opt-in direct GRO mode and the generic GRO ownership change it required. The series now retains the complete outer receive stack. - Preserve safe page-backed payload fragments during GSO segmentation and map them directly into the AEAD source scatterlist. - Reserve one consecutive packet-ID range for each UDP GSO batch instead of updating the counter once per segment. - Extend transmit prefetch to the first payload fragment of segments encrypted into a UDP GSO aggregate. - Refresh the GSO, GRO and prefetch measurements using two directly connected 100-Gbit/s mlx5 ports. Ralf Lici (8): ovpn: advertise checksum offload for GSO packets ovpn: accept frag-list GSO input ovpn: refactor AEAD encryption helpers ovpn: convert GSO input into UDP GSO output ovpn: reserve packet-ID ranges for UDP GSO batches ovpn: coalesce UDP data records with GRO ovpn: prefetch encrypted records before GRO batch decryption ovpn: prefetch GSO segments before encryption drivers/net/ovpn/crypto_aead.c | 171 +++++++++++++---- drivers/net/ovpn/crypto_aead.h | 4 + drivers/net/ovpn/io.c | 339 ++++++++++++++++++++++++++++++--- drivers/net/ovpn/io.h | 18 +- drivers/net/ovpn/main.c | 5 +- drivers/net/ovpn/pktid.h | 48 +++++ drivers/net/ovpn/proto.h | 4 + drivers/net/ovpn/skb.h | 27 ++- drivers/net/ovpn/stats.h | 16 +- drivers/net/ovpn/tcp.c | 4 +- drivers/net/ovpn/udp.c | 258 ++++++++++++++++++++++++- net/core/gro.c | 1 + net/ipv4/udp_offload.c | 3 +- 13 files changed, 810 insertions(+), 88 deletions(-) base-commit: b8e9e7d82e7eefd5d2d528469d94ec20e96b38c3