Article View: linux.kernel.netdev
Article #1374Re: [PATCH net-next] net: ag71xx: align the IP header behind DSA tags
From: Simon Horman
Date: Fri, 09 Oct 2026 16:47
Date: Fri, 09 Oct 2026 16:47
31 lines
6530 bytes
6530 bytes
On Wed, Oct 07, 2026 at 10:44:49AM -0700, Rosen Penev wrote: > The receive buffer offset includes NET_IP_ALIGN to get the IP header > aligned behind a 14 byte Ethernet header. Most ag71xx devices use DSA > switches whose tag sits in front of the EtherType, which moves the IP > header by another 2 bytes. Every access to the IP and TCP headers then > traps and gets emulated by the unaligned access handler, around 6 times > per forwarded frame. > > Take the headroom needed by the DSA tagger into account when choosing > the offset. > > TP-Link Archer C7 v2 (qca8k), median of 3 runs, Mbit/s: > > before after > routed up 743 855 > routed down 660 749 > local receive 554 572 > > The unaligned instruction counter no longer moves while forwarding. > > Assisted-by: LLM > Signed-off-by: Rosen Penev <rosenp@gmail.com> Unfortunately this patch did not apply cleanly to net-next at the time it was posted, so our CI did not run. Please rebase and repost. -- pw-bot: changes-requested
Technical Details
Message-ID:
<20261009164732.GG83879@horms.kernel.org>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-343809-linux-kernel-netdev=dewy.ruReferences:
<20261007174449.671416-1-rosenp@gmail.com>Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-343809-linux-kernel-netdev=dewy.ru From: horms@kernel.org (Simon Horman) Newsgroups: linux.kernel.netdev Subject: Re: [PATCH net-next] net: ag71xx: align the IP header behind DSA tags Date: Fri, 9 Oct 2026 17:47:32 +0100 Organization: Usenet Network Message-ID: <20261009164732.GG83879@horms.kernel.org> References: <20261007174449.671416-1-rosenp@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: usenet.network; logging-data="1150296"; mail-complaints-to="abuse@usenet.network" Cancel-Lock: sha1:3EbYpUpQ3aIzR7HRNKX+k0wd0Cs= sha256:fKWNivO3Mt2CqoeOk2ghlJbMAXcFYWktPBFh0HPPy4Q= sha1:BjLuYdXrWNA6FbTm0d4lo4aY07E= sha256:FojXBwwEYB7va6xJbcIQMk0CtUEVSIZ5pInNP+YOWo8= Content-Disposition: inline List-ID: <netdev.vger.kernel.org> X-Mailpost-Empty-Hdrs: X-Spam-Level X-Received: from localhost (localhost [127.0.0.1]) by mail.dewy.ru (Postfix) with ESMTP id B4A9410F743; Fri, 9 Oct 2026 19:52:54 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at usenet.network X-Spam-Flag: NO X-Spam-Score: -3.641 X-Spam-Status: No, score=-3.641 tagged_above=-9999 required=6.31 tests=[DCC_REPUT_70_89=0.1, DKIMWL_WL_HIGH=-0.241, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, MAILING_LIST_MULTI=-1, RCVD_IN_DNSWL_MED=-2.3, SPF_HELO_NONE=0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no X-Authentication-Results: mail.dewy.ru (amavisd-new); dkim=pass (2048-bit key) header.d=kernel.org X-Received: from mail.dewy.ru ([127.0.0.1]) by localhost (mail.dewy.ru [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id DyniIN6FRaIp; Fri, 9 Oct 2026 19:52:52 +0300 (MSK) X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.234.253.10; helo=sea.lore.kernel.org; envelope-from=netdev+bounces-343809-linux-kernel-netdev=dewy.ru@vger.kernel.org; receiver=<UNKNOWN> X-Authentication-Results: OpenDMARC; dmarc=pass (p=quarantine dis=none) header.from=kernel.org X-Received: from sea.lore.kernel.org (sea.lore.kernel.org [172.234.253.10]) by mail.dewy.ru (Postfix) with ESMTPS id AFD6F10F678; Fri, 9 Oct 2026 19:52:48 +0300 (MSK) X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.90.174.1]) by sea.lore.kernel.org (Postfix) with ESMTP id 411DB296F1; Fri, 9 Oct 2026 16:47:38 +0000 (UTC) X-Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 8F0D638F649; Fri, 9 Oct 2026 16:47:37 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="R9R1Lm9s" X-Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8940F38838F; Fri, 9 Oct 2026 16:47:36 +0000 (UTC) X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 X-ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1791564457; cv=none; b=LUtb16vFUv6s/HkkLBOGTN1wzUx62bptNxSgXm4aC6A3k6tYu+An8rADaEutmjlxxA1fhnFOOTGpID6zJMx2xOxW7PoKf2mZMjytb+C0K50RDe7xv8jushj1tYcnI/DOFarIWdcJ4XdCR+JWYkCBq4km36E5kD5ONPBNOTTBDEk= X-ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1791564457; c=relaxed/simple; bh=s5cEuLdlN+PPlUwWQ58v32ncF+mLLnHpBX7/MXR94xw=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=eWWqSjeqc4rt3Y3GJ+l4Qlhmdw/F5bSyXll9/FquBzKSyXhQCFHtpBaOtusUpA3/g86o8aYYbZiIl+sky/SlYYh1uZkBuLptVJdAN/5UFIaw8e/Oezf+/pck1cltJZQclHAFYur+ocAbrE2IeIttDqy4ZS9hmllKMDv2Wic5rqE= X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=R9R1Lm9s; arc=none smtp.client-ip=100.103.45.18 X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7D2D01F000FF; Fri, 9 Oct 2026 16:47:34 +0000 (UTC) X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1791564456; bh=0ZIVHrCq1ew1FhPHwVQ9oRt+nrgfNIPMv41G3Ez5E8E=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=R9R1Lm9suYUdjdSJxedpskqK6Qp7LUiKN6/eWE+TKp9Gyq7W4VE54LjMdYqXDt48Q DI+t26WB+/NsZBF+RAZF574+LbR6ha78Hl+n2NW6sEa9wqcVC3/MfFa9tvIvqpYqys QxEVh3y+Mq+wLV1/mBiaHkHfEZQxvS6fTGZMZD67fIsjAk8T28Qasdk8JvR/4vuuSf M8X3QhvWiTygJlbqbqpWebiyp+PMd4qdV/R9zOzTMaN+dmUzXle00yfFjqAD5wCvbV VF1HXxChauwkK5NMXA8J22dQes3AvdKlB0xYT69W+N6Ic90NwCqs54hsI0+4JZKJon 9BYN1S/90wexw== X-Cc: netdev@vger.kernel.org, Chris Snook <chris.snook@gmail.com>, Andrew Lunn <andrew+netdev@lunn.ch>, "David S. Miller" <davem@davemloft.net>, Eric Dumazet <edumazet@kernel.org>, Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>, open list <linux-kernel@vger.kernel.org> X-Precedence: bulk X-Mailing-List: netdev@vger.kernel.org X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org> X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org> X-In-Reply-To: <20261007174449.671416-1-rosenp@gmail.com>