From: Eric Dumazet <[email protected]>
Date: Thu, 30 Nov 2017 09:26:39 -0800
> On Thu, 2017-11-30 at 09:10 -0800, Stephen Hemminger wrote:
>>
>>
>> The problem goes back into the core GSO networking code.
>> Something like this is needed.
>>
>> static inline bool netif_needs_gso(struct sk_buff *skb,
>> const struct net_device *dev,
>> netdev_features_t features)
>> {
>> return skb_is_gso(skb) &&
>> (!skb_gso_ok(skb, features) ||
>> unlikely(skb_shinfo(skb)->gso_segs > dev-
>> >gso_max_segs) || << new
>> unlikely(skb_shinfo(skb)->gso_size > dev-
>> >gso_max_size) || << new
>> unlikely((skb->ip_summed != CHECKSUM_PARTIAL) &&
>> (skb->ip_summed != CHECKSUM_UNNECESSARY)));
>> }
>>
>> What that will do is split up the monster GSO packets if they ever
>> bleed
>> across from one device to another through the twisty mazes of packet
>> processing paths.
>
>
> Since very few drivers have these gso_max_segs / gso_max_size, check
> could be done in their ndo_features_check()
Agreed.