]> git.ipfire.org Git - thirdparty/linux.git/commit
bpf: Make bpf_skb_change_proto helper metadata-safe
authorJakub Sitnicki <jakub@cloudflare.com>
Wed, 5 Nov 2025 20:19:45 +0000 (21:19 +0100)
committerMartin KaFai Lau <martin.lau@kernel.org>
Mon, 10 Nov 2025 18:52:32 +0000 (10:52 -0800)
commit8cfc172ce28e6559d4d2d1a96df77f0f2d6179d6
tree48280867a8f9ba520c18a96c2ecb6409cde3233e
parentbe83105d38ab99737ac0488600efd59ddd57b74c
bpf: Make bpf_skb_change_proto helper metadata-safe

bpf_skb_change_proto reuses the same headroom operations as
bpf_skb_adjust_room, already updated to handle metadata safely.

The remaining step is to ensure that there is sufficient headroom to
accommodate metadata on skb_push().

Signed-off-by: Jakub Sitnicki <jakub@cloudflare.com>
Signed-off-by: Martin KaFai Lau <martin.lau@kernel.org>
Link: https://patch.msgid.link/20251105-skb-meta-rx-path-v4-8-5ceb08a9b37b@cloudflare.com
net/core/filter.c