Skip to content

net: minor gso encapsulation fixes

Florian Westphal netdev 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 1 replyIn review
  2. v13 of 4 patches 2 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3net: gso: use feature flag argument in all protocol gso handlersnet/ipv4/af_inet.c net/ipv4/gre_offload.c net/ipv4/udp_offload.c +2 more+5 -50 replies
2/3net: make skb_gso_segment error handling more robustnet/ipv4/ip_output.c net/netfilter/nfnetlink_queue_core.c net/openvswitch/datapath.c +1 more+6 -20 replies
3/3net: core: handle encapsulation offloads when computing segment lengthsnet/core/skbuff.c+10 -30 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH v2 0/3] net: minor gso encapsulation fixes

The following series fixes a minor bug in the gso segmentation handlers when encapsulation offload is used.

Theoretically this could cause kernel panic when the stack tries to software-segment such a GRE offload packet, but it looks like there is only one affected call site (tbf scheduler) and it handles NULL return value.

I've included a followup patch to add IS_ERR_OR_NULL checks where needed.

While looking into this, I also found that size computation of the individual segments is incorrect if skb->encapsulation is set.

Please see individual patches for delta vs. v1.

 core/skbuff.c                    |   13 ++++++++++---
 ipv4/af_inet.c                   |    2 +-
 ipv4/gre_offload.c               |    2 +-
 ipv4/ip_output.c                 |    2 +-
 ipv4/udp_offload.c               |    2 +-
 ipv6/ip6_offload.c               |    2 +-
 mpls/mpls_gso.c                  |    2 +-
 netfilter/nfnetlink_queue_core.c |    2 +-
 openvswitch/datapath.c           |    2 ++
 xfrm/xfrm_output.c               |    2 ++
 10 files changed, 21 insertions(+), 10 deletions(-)