diff --git a/Makefile b/Makefile index 3937e96d463f5d..9fcf204d08afe8 100644 --- a/Makefile +++ b/Makefile @@ -1,7 +1,7 @@ # SPDX-License-Identifier: GPL-2.0 VERSION = 5 PATCHLEVEL = 15 -SUBLEVEL = 204 +SUBLEVEL = 205 EXTRAVERSION = NAME = Trick or Treat diff --git a/net/ipv4/esp4.c b/net/ipv4/esp4.c index c69cee3feff001..0b062959871fa6 100644 --- a/net/ipv4/esp4.c +++ b/net/ipv4/esp4.c @@ -921,7 +921,8 @@ static int esp_input(struct xfrm_state *x, struct sk_buff *skb) nfrags = 1; goto skip_cow; - } else if (!skb_has_frag_list(skb)) { + } else if (!skb_has_frag_list(skb) && + !skb_has_shared_frag(skb)) { nfrags = skb_shinfo(skb)->nr_frags; nfrags++; diff --git a/net/ipv4/ip_output.c b/net/ipv4/ip_output.c index d674a24217f90f..68509e1f89b5b0 100644 --- a/net/ipv4/ip_output.c +++ b/net/ipv4/ip_output.c @@ -1443,6 +1443,8 @@ ssize_t ip_append_page(struct sock *sk, struct flowi4 *fl4, struct page *page, goto error; } + skb_shinfo(skb)->tx_flags |= SKBFL_SHARED_FRAG; + if (skb->ip_summed == CHECKSUM_NONE) { __wsum csum; csum = csum_page(page, offset, len); diff --git a/net/ipv6/esp6.c b/net/ipv6/esp6.c index e87f3f8f068186..0aaafc0bd8fa6a 100644 --- a/net/ipv6/esp6.c +++ b/net/ipv6/esp6.c @@ -968,7 +968,8 @@ static int esp6_input(struct xfrm_state *x, struct sk_buff *skb) nfrags = 1; goto skip_cow; - } else if (!skb_has_frag_list(skb)) { + } else if (!skb_has_frag_list(skb) && + !skb_has_shared_frag(skb)) { nfrags = skb_shinfo(skb)->nr_frags; nfrags++;