From: Eric Dumazet <eduma...@google.com> Date: Wed, 18 Apr 2018 11:43:15 -0700
> After working on IP defragmentation lately, I found that some large > packets defeat CHECKSUM_COMPLETE optimization because of NIC adding > zero paddings on the last (small) fragment. > > While removing the padding with pskb_trim_rcsum(), we set skb->ip_summed > to CHECKSUM_NONE, forcing a full csum validation, even if all prior > fragments had CHECKSUM_COMPLETE set. Oops. > We can instead compute the checksum of the part we are trimming, > usually smaller than the part we keep. > > Signed-off-by: Eric Dumazet <eduma...@google.com> Looks good, applied, thanks Eric.