diff options
author | David S. Miller | 2023-06-20 13:33:50 +0100 |
---|---|---|
committer | David S. Miller | 2023-06-20 13:33:50 +0100 |
commit | e438edaae26ce80c3fcc498fbba0c8f7e78497e5 (patch) | |
tree | 077dc534801399df737853197ebef71265c83019 /net/ipv6 | |
parent | 440d71e2edf283465c7a9ed151efd589d71b6307 (diff) | |
parent | f015b900bc3285322029b4a7d132d6aeb0e51857 (diff) |
Merge tag 'ipsec-2023-06-20' of git://git.kernel.org/pub/scm/linux/kernel/git/klassert/ipsec
ipsec-2023-06-20
Diffstat (limited to 'net/ipv6')
-rw-r--r-- | net/ipv6/esp6_offload.c | 3 | ||||
-rw-r--r-- | net/ipv6/xfrm6_input.c | 3 |
2 files changed, 6 insertions, 0 deletions
diff --git a/net/ipv6/esp6_offload.c b/net/ipv6/esp6_offload.c index 75c02992c520..772340268997 100644 --- a/net/ipv6/esp6_offload.c +++ b/net/ipv6/esp6_offload.c @@ -374,6 +374,9 @@ static int esp6_xmit(struct xfrm_state *x, struct sk_buff *skb, netdev_features secpath_reset(skb); + if (skb_needs_linearize(skb, skb->dev->features) && + __skb_linearize(skb)) + return -ENOMEM; return 0; } diff --git a/net/ipv6/xfrm6_input.c b/net/ipv6/xfrm6_input.c index 04cbeefd8982..4907ab241d6b 100644 --- a/net/ipv6/xfrm6_input.c +++ b/net/ipv6/xfrm6_input.c @@ -86,6 +86,9 @@ int xfrm6_udp_encap_rcv(struct sock *sk, struct sk_buff *skb) __be32 *udpdata32; __u16 encap_type = up->encap_type; + if (skb->protocol == htons(ETH_P_IP)) + return xfrm4_udp_encap_rcv(sk, skb); + /* if this is not encapsulated socket, then just return now */ if (!encap_type) return 1; |