summaryrefslogtreecommitdiff
path: root/net/ipv4/udp_offload.c
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2024-05-13 14:44:13 -0700
committerJakub Kicinski <kuba@kernel.org>2024-05-13 14:44:13 -0700
commite6e43570fd98ac609c903bc91d6db163ba2e82d0 (patch)
tree1a1e029a9f9feb22836769c4ff8a4b715fd39fd6 /net/ipv4/udp_offload.c
parent9af9b891fc6b44bb336933d63be526ca5cc6ee25 (diff)
parentbc21faefbe58feff0ae7cae8b52c4145073e2208 (diff)
downloadlinux-e6e43570fd98ac609c903bc91d6db163ba2e82d0.tar.gz
linux-e6e43570fd98ac609c903bc91d6db163ba2e82d0.tar.bz2
linux-e6e43570fd98ac609c903bc91d6db163ba2e82d0.zip
Merge branch 'net-gro-remove-network_header-use-move-p-flush-flush_id-calculations-to-l4'
Richard Gobert says: ==================== net: gro: remove network_header use, move p->{flush/flush_id} calculations to L4 The cb fields network_offset and inner_network_offset are used instead of skb->network_header throughout GRO. These fields are then leveraged in the next commit to remove flush_id state from napi_gro_cb, and stateful code in {ipv6,inet}_gro_receive which may be unnecessarily complicated due to encapsulation support in GRO. These fields are checked in L4 instead. 3rd patch adds tests for different flush_id flows in GRO. ==================== Link: https://lore.kernel.org/r/20240509190819.2985-1-richardbgobert@gmail.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/ipv4/udp_offload.c')
-rw-r--r--net/ipv4/udp_offload.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/net/ipv4/udp_offload.c b/net/ipv4/udp_offload.c
index f6d3c442e260..59448a2dbf2c 100644
--- a/net/ipv4/udp_offload.c
+++ b/net/ipv4/udp_offload.c
@@ -478,14 +478,7 @@ static struct sk_buff *udp_gro_receive_segment(struct list_head *head,
return p;
}
- flush = NAPI_GRO_CB(p)->flush;
-
- if (NAPI_GRO_CB(p)->flush_id != 1 ||
- NAPI_GRO_CB(p)->count != 1 ||
- !NAPI_GRO_CB(p)->is_atomic)
- flush |= NAPI_GRO_CB(p)->flush_id;
- else
- NAPI_GRO_CB(p)->is_atomic = false;
+ flush = gro_receive_network_flush(uh, uh2, p);
/* Terminate the flow on len mismatch or if it grow "too much".
* Under small packet flood GRO count could elsewhere grow a lot