]> git.baikalelectronics.ru Git - kernel.git/commit
net: Fix esp GSO on inter address family tunnels.
authorSteffen Klassert <steffen.klassert@secunet.com>
Mon, 7 Mar 2022 12:11:41 +0000 (13:11 +0100)
committerSteffen Klassert <steffen.klassert@secunet.com>
Mon, 7 Mar 2022 12:14:04 +0000 (13:14 +0100)
commit11d70a3bf7b25103995a3f83e1c39c6f799ec38d
tree3a2cce55445d12ac2ed9131bf45a518b1a999bfd
parenta4b019b40cf22d54a016d25ebc12ab6ba6a0741e
net: Fix esp GSO on inter address family tunnels.

The esp tunnel GSO handlers use skb_mac_gso_segment to
push the inner packet to the segmentation handlers.
However, skb_mac_gso_segment takes the Ethernet Protocol
ID from 'skb->protocol' which is wrong for inter address
family tunnels. We fix this by introducing a new
skb_eth_gso_segment function.

This function can be used if it is necessary to pass the
Ethernet Protocol ID directly to the segmentation handler.
First users of this function will be the esp4 and esp6
tunnel segmentation handlers.

Fixes: 040d19a90076 ("xfrm: Add mode handlers for IPsec on layer 2")
Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
include/linux/netdevice.h
net/core/gro.c
net/ipv4/esp4_offload.c
net/ipv6/esp6_offload.c