]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ipvs: pass parsed transport offset to state handlers
authorYizhou Zhao <zhaoyz24@mails.tsinghua.edu.cn>
Mon, 6 Jul 2026 10:16:22 +0000 (18:16 +0800)
committerFlorian Westphal <fw@strlen.de>
Wed, 8 Jul 2026 13:33:44 +0000 (15:33 +0200)
commitbae7ce7bafb59e42dc0e0e2999fdd9d1cffe3866
treeea27349d925829b2a7ba6cf97a031aaa63aee3cc
parentda5b58478a9c1b85608c9e40a3b8432d071b409e
ipvs: pass parsed transport offset to state handlers

IPVS callers already parse the packet into struct ip_vs_iphdr before
updating connection state. For IPv6 this records the real
transport-header offset after extension headers in iph.len.

Pass this parsed transport offset through ip_vs_set_state() and the
protocol state_transition() callback so protocol handlers can use the
same packet context as scheduling and NAT handling. This patch only
changes the common callback plumbing and adapts the protocol callback
signatures; TCP and SCTP start using the value in follow-up patches.

Signed-off-by: Yizhou Zhao <zhaoyz24@mails.tsinghua.edu.cn>
Acked-by: Julian Anastasov <ja@ssi.bg>
Signed-off-by: Florian Westphal <fw@strlen.de>
include/net/ip_vs.h
net/netfilter/ipvs/ip_vs_core.c
net/netfilter/ipvs/ip_vs_proto_sctp.c
net/netfilter/ipvs/ip_vs_proto_tcp.c
net/netfilter/ipvs/ip_vs_proto_udp.c