Skip to contentSkip to conversation

geneve: fix length used in GRO hint UDP checksum adjustment

PATCH Applied Antoine Tenart 3 participants 3 messages May 29 – Jun 4

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 geneve: fix length used in GRO hint UDP checksum adjustment

In geneve_post_decap_hint the length used for adjusting the UDP checksum should be 'skb->len - gro_hint->nested_tp_offset' (UDP length) instead of 'skb->len - gro_hint->nested_nh_offset' (IP length).

Fixes fd0dd796576e ("geneve: use GRO hint option in the RX path")
Cc Paolo Abeni <[email protected]>
---
 drivers/net/geneve.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/geneve.c +1 -1
index c6563367d382..715180c3a1b3 100644
@@ -632,7 +632,7 @@ static int geneve_post_decap_hint(const struct sock *sk, struct sk_buff *skb,
 	uh = udp_hdr(skb);
 	uh->len = htons(skb->len - gro_hint->nested_tp_offset);
 	if (uh->check) {
-		len = skb->len - gro_hint->nested_nh_offset;
+		len = skb->len - gro_hint->nested_tp_offset;
 		skb_shinfo(skb)->gso_type |= SKB_GSO_UDP_TUNNEL_CSUM;
 		if (gro_hint->nested_is_v6)
 			uh->check = ~udp_v6_check(len, &ipv6h->saddr,
Signature · 1 line
2.54.0
reviewer Reviewed-by on v1 1/1
#1 lore raw
Quoted 9 lines · Antoine Tenart

In geneve_post_decap_hint the length used for adjusting the UDP checksum should be 'skb->len - gro_hint->nested_tp_offset' (UDP length) instead of 'skb->len - gro_hint->nested_nh_offset' (IP length).

Fixes fd0dd796576e ("geneve: use GRO hint option in the RX path")
Cc Paolo Abeni <[email protected]>

FTR, an AI-generated review of this patch is available on sashiko.dev. I do not believe that needs to be addressed in the context of this patch.

#2 lore raw
In reply to Antoine Tenart
This patch was applied to netdev/net.git (main) by Paolo Abeni <[email protected]>:

Hello:

This patch was applied to netdev/net.git (main)
by Paolo Abeni <[email protected]>:

Quoted 11 lines · On Fri, 29 May 2026 16:47:00 +0200 you wrote:

In geneve_post_decap_hint the length used for adjusting the UDP checksum should be 'skb->len - gro_hint->nested_tp_offset' (UDP length) instead of 'skb->len - gro_hint->nested_nh_offset' (IP length).

Fixes fd0dd796576e ("geneve: use GRO hint option in the RX path")
Cc Paolo Abeni <[email protected]>

[...]

Here is the summary with links:
- [net] geneve: fix length used in GRO hint UDP checksum adjustment

    https://git.kernel.org/netdev/net/c/1231623fd3b5

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html