From patchwork Mon Nov 16 08:06:03 2026 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gert Doering X-Patchwork-Id: 5707 Return-Path: Delivered-To: patchwork@openvpn.net Received: by 2002:a05:6022:9292:b0:11a:f58a:e788 with SMTP id dc18csp888832lab; Mon, 16 Nov 2026 00:06:27 -0800 (PST) X-Forwarded-Encrypted: i=2; AL+hErGpYUKzFaDurtW6baxSvn8BfKEGnow8NZxGeq9muO8wZhrIs+PiGNkljO6SQWqrS26dA18rtvgAPg0=@openvpn.net X-Received: by 2002:a05:7301:1527:b0:36c:a26f:83c4 with SMTP id 5a478bee46e88-377e101681cmr12442770eec.13.1794816387148; Mon, 16 Nov 2026 00:06:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1794816387; cv=none; d=google.com; s=arc-20260327; b=BK0XWu9ejQwPjBsfCoxkYPOtRxw8YQWd7wqzEYuMb9xh0ElpPb+yRiS5v+N/uUgcC5 G+z7PUfhPOgNPnvQy7i4JF2msppDwS98qSxHvfqbRuFB9EpT6UVyZx3lV84uQR4l3A9H WQ/31cHmkVtJzEjcdacKFM1O06eHUD1mkkjZ7yoYEHMS6MUMu049T92CISmFu6TZePMy aHz+WS2PSrpHyCt/WeRGzAVSeiwuZ5ZTwY2jQ1MexTpaYNTonsdrs1KLrNCNxDy70HJ9 P72Vb0kO+hqqCURpwRJ42AFyFozUvKWNPfj12h6DkVPdeSLUQGsYzc+L6iJ/r9N0eaeY tzNg== 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:references:in-reply-to:message-id:date:to:from :dkim-signature:dkim-signature:dkim-signature; bh=dmMKfr2TUnCZCo0FEbCXUaQmwbLq7BG0xfKzta6fQJI=; fh=4NbAC/LsuMLI0S0hprUlLSLCiHwg6SCAifhH718Jh0Q=; b=JLHd4lsG0SvYCPOahh4oHDqB6eIYbsYEJoPcHsbxGBZaPkq7jugWMbEBPv5v6FIjTa eCYCGtaGASnw6OjveoTdMXHVFSejJitDqDFEwYpUYR9cr/eWWq8+qtCmdWCRucg9UG2z cn6uf6axdJce5vF3DOG1y8bdT4CYvPJrhgE2zqw1HaJSv5X5+UU4IfoASv2JSCLORnIB ubWFA6qlY+hDyAxGKo70s3ymWYznjirQq7sade/hMc62YqHe1cUICUO/YTAhoGWuw9ah Gid4DSFfhgGf0hDK181Ybj+8FXWjN10CV9ihbtD2jCALbF2TQXgRqLp03eWpK0I2k2HM +F+g==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lists.sourceforge.net header.s=beta header.b=VK1UxwTK; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b="OF2/eSxc"; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=LcpJ8amu; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=muc.de Received: from lists.sourceforge.net (lists.sourceforge.net. [216.105.38.7]) by mx.google.com with ESMTPS id 5a478bee46e88-3795ab727b9si42929283eec.55.2026.11.16.00.06.26 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 16 Nov 2026 00:06:27 -0800 (PST) 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=VK1UxwTK; dkim=neutral (body hash did not verify) header.i=@sourceforge.net header.s=x header.b="OF2/eSxc"; dkim=neutral (body hash did not verify) header.i=@sf.net header.s=x header.b=LcpJ8amu; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=muc.de 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:References:In-Reply-To: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:List-Unsubscribe-Post: List-Owner; bh=dmMKfr2TUnCZCo0FEbCXUaQmwbLq7BG0xfKzta6fQJI=; b=VK1UxwTK5V2Cch XiRAvTm7xioAJmSXH8AsJ3pm2ce3l3UsHZ/yLblj9JrDQi3ymTcck+D4rGEH339/FEJyeuupcwdG0 pai8wm5ke49qasoenYsdPcCvioAuqCHbiAzqd923cPqacv3paAFRRG6df/TwguCwDb3COe7sx+XfF llY=; 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.100.1) (envelope-from ) id 1xSrjJ-000000008RR-34LD; Mon, 16 Nov 2026 08:06:21 +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.100.1) (envelope-from ) id 1xSrjI-000000008RA-0sg5 for openvpn-devel@lists.sourceforge.net; Mon, 16 Nov 2026 08:06:20 +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:References: In-Reply-To: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:List-Id:List-Help:List-Unsubscribe: List-Unsubscribe-Post:List-Subscribe:List-Post:List-Owner:List-Archive; bh=MZynpih1KuOUMYO0VSCTHo6PTx23ko4QvhBKFguDHTQ=; b=OF2/eSxczU6xq/6xYp2FtTk+IW F/Ffs7Kg16Oz1ZHxAB8H+clixlzO9qjupLnTjsq3uEDoi9oGIOBgac2uJYMbl88u9O+Fnl0AzAFyy YEtSvHVdyfaEHeSijRHpzAVks64I58In9kHEd9UFDJ6BuXblAzwF5Qfw/yIkxxlTw06A=; DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sf.net; s=x ; h=Content-Transfer-Encoding:MIME-Version:References:In-Reply-To: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:List-Id:List-Help:List-Unsubscribe:List-Unsubscribe-Post: List-Subscribe:List-Post:List-Owner:List-Archive; bh=MZynpih1KuOUMYO0VSCTHo6PTx23ko4QvhBKFguDHTQ=; b=LcpJ8amukjCymjDua6DWyV48F3 yIyNyfUgLDY1vDGuay/53LnsCmGjJ9e8MtUDdP8fnYans7HLIcbNUKbdk8a2zd2OqjmRGACXbk4Jw J8xi7V4U+lsCcP4Pbq8XNE48i80Bl0g9FBLHc9O7tbZrH3MckqBGseH15Z5sUYLCTr2U=; Received: from [193.149.48.129] (helo=blue.greenie.muc.de) by sfi-mx-2.v28.lw.sourceforge.com with esmtps (TLS1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.100.1) id 1xSrjF-000000005IJ-03qu for openvpn-devel@lists.sourceforge.net; Mon, 16 Nov 2026 08:06:20 +0000 Received: from blue.greenie.muc.de (localhost [127.0.0.1]) by blue.greenie.muc.de (8.18.1/8.18.1) with ESMTP id 6AG86A4R000504 for ; Mon, 16 Nov 2026 09:06:10 +0100 Received: (from gert@localhost) by blue.greenie.muc.de (8.18.2/8.18.1/Submit) id 6AG86AvN000489 for openvpn-devel@lists.sourceforge.net; Mon, 16 Nov 2026 09:06:10 +0100 From: Gert Doering To: openvpn-devel@lists.sourceforge.net Date: Mon, 16 Nov 2026 09:06:03 +0100 Message-ID: <20261116080609.440-1-gert@greenie.muc.de> X-Mailer: git-send-email 2.55.0 In-Reply-To: References: MIME-Version: 1.0 X-Spam-Score: 1.3 (+) 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: From: Razvan Cojocaru The kernel ignores the flag since Linux 3.8, commit 5d097109257c ("tun: only queue packets on device"). Also drop its guard around the --txqueuelen code, since SIOCSIFTXQLEN is always available, and t [...] Content analysis details: (1.3 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 1.3 RDNS_NONE Delivered to internal network by a host with no rDNS X-Headers-End: 1xSrjF-000000005IJ-03qu Subject: [Openvpn-devel] [PATCH v1] tun: drop no-op IFF_ONE_QUEUE on Linux X-BeenThere: openvpn-devel@lists.sourceforge.net X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: openvpn-devel-bounces@lists.sourceforge.net X-getmail-retrieved-from-mailbox: Inbox X-GMAIL-THRID: 1882001388106044176 X-GMAIL-MSGID: 1882001388106044176 From: Razvan Cojocaru The kernel ignores the flag since Linux 3.8, commit 5d097109257c ("tun: only queue packets on device"). Also drop its guard around the --txqueuelen code, since SIOCSIFTXQLEN is always available, and the stale --tun-ipv6 comment. Drop the outdated kernel version and init script note from INSTALL. Change-Id: I272f840b547dde968ceca2c24de5a922f0721149 Signed-off-by: Razvan Cojocaru Acked-by: Gert Doering Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2185 --- This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master. Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/2185 This mail reflects revision 1 of this Change. Acked-by according to Gerrit (reflected above): Gert Doering diff --git a/INSTALL b/INSTALL index d0ffaf0..0484e98 100644 --- a/INSTALL +++ b/INSTALL @@ -226,13 +226,10 @@ TUN/TAP Driver References: -* Linux 2.6 or higher (with integrated TUN/TAP driver): +* Linux (with integrated TUN/TAP driver): - (1) load driver: modprobe tun - (2) enable routing: echo 1 > /proc/sys/net/ipv4/ip_forward - - Note that (1) needs to be done once per reboot. If you install from RPM (see - above) and use the openvpn.init script, these steps are taken care of for you. + (1) load driver (only if /dev/net/tun is missing): modprobe tun + (2) enable routing: echo 1 > /proc/sys/net/ipv4/ip_forward * FreeBSD: diff --git a/src/openvpn/tun.c b/src/openvpn/tun.c index 70fdd7e..0ba8a4a 100644 --- a/src/openvpn/tun.c +++ b/src/openvpn/tun.c @@ -2123,16 +2123,9 @@ msg(M_ERR, "ERROR: Cannot open TUN/TAP dev %s", node); } - /* - * Process --tun-ipv6 - */ CLEAR(ifr); ifr.ifr_flags = IFF_NO_PI; -#if defined(IFF_ONE_QUEUE) && defined(SIOCSIFTXQLEN) - ifr.ifr_flags |= IFF_ONE_QUEUE; -#endif - #ifdef IFF_BACKPRESSURE ifr.ifr_flags |= IFF_BACKPRESSURE; #endif @@ -2175,7 +2168,6 @@ /* * Try making the TX send queue bigger */ -#if defined(IFF_ONE_QUEUE) && defined(SIOCSIFTXQLEN) if (tt->options.txqueuelen) { struct ifreq netifr; @@ -2201,7 +2193,6 @@ msg(M_WARN | M_ERRNO, "Note: Cannot open control socket on %s", ifr.ifr_name); } } -#endif /* if defined(IFF_ONE_QUEUE) && defined(SIOCSIFTXQLEN) */ set_nonblock(tt->fd); set_cloexec(tt->fd);