🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: linux.kernel.netdev
Article #13945

Re: [PATCH net 0/2] net: fix mac_len of skbs copied by generic XDP

#13945
From: patchwork-bot+netdevbpf
Date: Tue, 10 Nov 2026 14:30
35 lines
9523 bytes
Hello:

This series was applied to netdev/net.git (main)
by Paolo Abeni <pabeni@redhat.com>:

On Tue,  3 Nov 2026 20:00:35 +0000 you wrote:
> Generic XDP copies the skb before it runs a program with frags support.
> The copy happens when the skb is cloned, nonlinear, or has less than 256
> bytes of headroom. skb_pp_cow_data() makes the copy, but it does not
> copy mac_len. After XDP, the skb has mac_len 0.
> 
> Two places after generic XDP move skb->data by mac_len:
> - On XDP_REDIRECT to a cpumap, cpu_map_generic_redirect() pulls mac_len
>   bytes, the length of the Ethernet header. Then it queues the skb to
>   the target CPU. With mac_len 0, the IP layer on that CPU sees the
>   Ethernet header and drops the packet.
> - On XDP_PASS, the skb can go on to tc ingress with a BPF program
>   attached (tcx, cls_bpf or act_bpf). Before it runs the program, tc
>   pushes mac_len bytes, the length of the Ethernet header. With
>   mac_len 0, skb->data stays at the IP header. Therefore, the program
>   reads the IP header as the Ethernet header.
> 
> [...]

Here is the summary with links:
  - [net,1/2] net: fix mac_len of skbs copied by generic XDP
    https://git.kernel.org/netdev/net/c/71578e43b8a6
  - [net,2/2] selftests: drv-net: ping: test generic XDP redirect to cpumap
    https://git.kernel.org/netdev/net/c/71b116cf334b

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
Technical Details
Message-ID: <179432100643.3999302.15619209426166377365.git-patchwork-notify@kernel.org>
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-360318-linux-kernel-netdev=dewy.ru
References: <20261103200036.65764-2-tianyi@cloudflare.com>

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-lax.pugleaf.net!srl.newsdeef.eu!news.mb-net.net!open-news-network.org!news.nntp4.net!nntp.xenet.de!news.neodome.net!usenet.network!.POSTED!vger.kernel.org!netdev+bounces-360318-linux-kernel-netdev=dewy.ru
From: patchwork-bot+netdevbpf@kernel.org
Newsgroups: linux.kernel.netdev
Subject: Re: [PATCH net 0/2] net: fix mac_len of skbs copied by generic XDP
Date: Tue, 10 Nov 2026 14:30:06 +0000
Organization: Usenet Network
Message-ID: <179432100643.3999302.15619209426166377365.git-patchwork-notify@kernel.org>
References: <20261103200036.65764-2-tianyi@cloudflare.com>
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: 8bit
Injection-Info: usenet.network;
	logging-data="626988"; mail-complaints-to="abuse@usenet.network"
Cancel-Lock: sha1:Fgb+I/G8PmwOc5Ozfm0jKTFaHwE= sha256:/3I0+T5ODFBk2sJYPlkxyf8jT9e5DmisrXNf+p13veE=
	sha1:0R9kuGhRVl5KO88Ga67d5hXEJ10= sha256:eAOFTl+wPp5H+SD3CaAobB9IBi5R4MaKMdi6niySY8A=
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 829C3113BCF; Tue, 10 Nov 2026 17:31:05 +0300 (MSK)
X-Virus-Scanned: Debian amavisd-new at usenet.network
X-Spam-Flag: NO
X-Spam-Score: -3.501
X-Spam-Status: No, score=-3.501 tagged_above=-9999 required=6.31
	tests=[DKIMWL_WL_HIGH=-0.001, 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 CjYr6KsZmRfn;
	Tue, 10 Nov 2026 17:31:02 +0300 (MSK)
X-Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=172.232.135.74; helo=sto.lore.kernel.org; envelope-from=netdev+bounces-360318-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 sto.lore.kernel.org (sto.lore.kernel.org [172.232.135.74])
	by mail.dewy.ru (Postfix) with ESMTPS id 3A683113BD9; Tue, 10 Nov 2026 17:30:53 +0300 (MSK)
X-Received: from smtp.subspace.kernel.org (conduit.subspace.kernel.org [100.77.114.92])
	by sto.lore.kernel.org (Postfix) with ESMTP id CB8C5605FC6; Tue, 10 Nov 2026 14:30:20 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org; arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-ARC-Seal: i=2; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=pass;
	t=1794321019;
	b=h3e4KTvhzBu7GN5tKP7280s3GrS9gRairj9kD/bqF3agrCqL4pPWL7D/rAGVe9MjLxIN
	 tWoyEkH39XjGPkaLGl/0c2eND+/gfRrJgM/66MH1qK/50IlOoKPij2GOi5+8u9f+ksRJs
	 YUy6yW/A+o0tjMdBIWOHAegEvv6PMZnaI2cpfIuFvfXJM6phUt08LF852gBRHkt76n+CH
	 KW2wW7QhSnADtCns+Nn2Su4otl2CcHQQ6A/OSXaGb6LOIpt4jqnId752vsaxpE2/tAKgW
	 WWUwz0c67MdBfwbAXcFafD51rJXE1fii7DrxYR0MFqzjrS/LIUuXcOV9MPBLEku4Erw==
X-ARC-Message-Signature: i=2; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794321019;
	h=X-Original-To:Received:Received:DKIM-Signature:Received:Content-Type:
	 X-Mailing-List:List-Id:List-Post:List-Help:List-Subscribe:
	 List-Unsubscribe:List-Owner:Precedence:MIME-Version:
	 Content-Transfer-Encoding:Subject:From:Message-Id:Date:References:
	 In-Reply-To:To:Cc;
	bh=6re/8M7BAKbsJAaby7V03QwRwM9/MqNLLzk54nsXA00=;
	b=o2wIx4s5SFO9ptdkH5H+WaBLDIzazwI0qEzZK/9b0AOQkihUEuhwcDZNrgo0Qf54sk7E
	 hY0lmQysjy4JsNxFbDN787nNh4LAP6oDrN5Ng9Dxk9ZleEjnwA9bgBuxvy3Iwr8fcgWMO
	 t6IubE2Ifxg3p/kJQ19PY1yUYvGwo+SLxdNIPutvzqwz8s7FFsgZGx0z+I4R9RABwZ3ac
	 swc5+DkV87l+iAKg+lO0knqbXwPYOCXxXiflddKtoRBvScVPr+wz4nI38VE7HbfvoFTK9
	 YOyOB3+8aZKUdLwRsNJKAENQd+rkIaCLPnExnusU3QycbbvtqXd5U5W1H3OMY6lLZ0w==
X-ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; 
	dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=JlqNEHB0;
	arc=pass header.oldest-pass=0 smtp.remote-ip=127.0.0.1
X-Received: from localhost.localdomain (localhost [127.0.0.1])
	by smtp.subspace.kernel.org (Postfix) with ESMTP id 4DF45606A32E;
	Tue, 10 Nov 2026 14:30:19 +0000 (UTC)
X-Authentication-Results: smtp.subspace.kernel.org;
	dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=JlqNEHB0
X-Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=100.103.45.18
X-ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none;
	t=1794321008;
	b=q9e2LlGK4Y60/KmEMDuw/BPxRkdawQTeJBb9HLl+4hz9rDz5fH6Onz/gojaHeNx2TksK
	 XXR4Z0KkrXCs0rJUeSVriJig2710B3gcqYNJ8ce4pfs6nX954snbwojioQF2RCs1h1SiW
	 Xhnm4fVgmWdnUMC/WU/Z18tzOi4xE9uTWfF3J/Q7ia7T/NYdh9emxbCBryJ5llbw0d7QZ
	 JaXMfwYz9hlHZS5ersCnWjtKa8j2adNAsy0r/IW8cFwUu9hn1i9VI7coxhvFwn6dRdOcg
	 f8vcGkXpjRuKiHzjgK3ghE2OoK06deo3/wfncZGaoGE6xkPEFoIB6yxsuYslmXjjAeA==
X-ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015;
	a=rsa-sha256; c=relaxed/relaxed; t=1794321008;
	h=Received:DKIM-Signature:Received:Content-Type:MIME-Version:
	 Content-Transfer-Encoding:Subject:From:Message-Id:Date:References:
	 In-Reply-To:To:Cc;
	bh=6re/8M7BAKbsJAaby7V03QwRwM9/MqNLLzk54nsXA00=;
	b=A8X7K2S7c88Mp95r51kLcO0sf/ypWipKLTHzo6xkatL1FCUj5UVK5uqqVde0LBlc9Vyr
	 u9rrVFJ6qBv3zhJHpKVxTFfOvyEPK9MCNmaQxw6/qi+ywJIqsQ7DLj76SWnvUxkwUvLkc
	 /kmQ0lU4RqlG2YTcOTyQlkjUuKYfvVWFb/Cyse2hl+c8XW1MxWdPPOIZHwQYowlKUVCh7
	 lwhPIngTNgaJpaPP8qAZsiRKRIccwiRbHbumTyW79AcJltGHp07GYTN4PSixQmpuMadi/
	 d25OQdiC2m2MDXwhqWWDCuWQXlGKUNJWV3IQw7hR4sXrGcqrFOIsTf7JaqbZCIdGasw==
X-ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; 
	dkim=pass header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=JlqNEHB0;
	arc=none smtp.remote-ip=100.103.45.18
X-Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature ECDSA (prime256v1))
	(No client certificate requested)
	by smtp.subspace.kernel.org (Postfix) with ESMTPS id 2B07D606A321;
	Tue, 10 Nov 2026 14:30:07 +0000 (UTC)
X-Received: by smtp.kernel.org (Postfix) with ESMTPSA id A819E1F0089F;
	Tue, 10 Nov 2026 14:30:07 +0000 (UTC)
X-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org;
	s=k20260515; t=1794321007;
	bh=6re/8M7BAKbsJAaby7V03QwRwM9/MqNLLzk54nsXA00=;
	h=Subject:From:Date:References:In-Reply-To:To:Cc;
	b=JlqNEHB0x83jrWOU+aXt+t6KdxBWq2a0su5gwKhZDBDzwdt1vIQ+NwqadIVD620Jl
	 ZMlJKnzaNQn8mqKyJ431cKwCEnd14z50i39yzmzWsET+nkfQI0rpvua3TRIDtlNlIs
	 7KNJgu85+cPAH0ouhch2WhSEoivO1FCxEzftHMCnDRMIwOywBFSqKLXWsH/34mPlV9
	 6Z/vZWe/lIqMC5Cnyp86SOtVRvWI/qdbB0K6nMI9TKgEONPlilb/c8gOfxOH8CpsqH
	 giLI4Stt/6YsFC+0yROroPr0/dQcoL6af4eM2KZEYtFU7qm6auzjkc3xxDdGbx1W7+
	 N39ZX/MLnwP6Q==
X-Received: from [10.30.226.235] (localhost [IPv6:::1])
	by aws-us-west-2-korg-oddjob-rhel9-1.codeaurora.org (Postfix) with ESMTP id 9B09D39D0CA0;
	Tue, 10 Nov 2026 14:30:07 +0000 (UTC)
X-Mailing-List: netdev@vger.kernel.org
X-List-Post: <mailto:netdev@vger.kernel.org>
X-List-Help: <mailto:netdev+help@vger.kernel.org>
X-List-Subscribe: <mailto:netdev+subscribe@vger.kernel.org>
X-List-Unsubscribe: <mailto:netdev+unsubscribe@vger.kernel.org>
X-List-Owner: <mailto:netdev+owner@vger.kernel.org>
X-Precedence: list
X-In-Reply-To: <20261103200036.65764-2-tianyi@cloudflare.com>
X-Cc: netdev@vger.kernel.org, davem@davemloft.net, edumazet@kernel.org,
 kuba@kernel.org, pabeni@redhat.com, horms@kernel.org, andrew+netdev@lunn.ch,
 shuah@kernel.org, ast@kernel.org, daniel@iogearbox.net, hawk@kernel.org,
 john.fastabend@gmail.com, sdf@fomichev.me, lorenzo@kernel.org,
 toke@redhat.com, linux-kselftest@vger.kernel.org, bpf@vger.kernel.org,
 kernel-team@cloudflare.com